<input type="number" min="100" max="125" value="105" onchange="document.getElementById('hex').value=this.valueAsNumber.toString(16).toUpperCase()" /> 0x<output id="hex">69</output>