HTML input number and read only To make a HTML input read only use this code: XHTML <input type="text" value="readonly" readonly> 1 <input type="text" value="readonly" readonly> Try it: To make a HTML input type to a number use this code: XHTML <input value="0" type="number"> 1 <input value="0" type="number"> Try it: