Html – ny way to prevent input type=”number” getting negative values

htmlinputnumbers

I want to get only positive values, is there any way to prevent it using only html
Please don't suggest validation method

Screenshot of input control

Best Answer

Use the min attribute like this:

<input type="number" min="0">