Skip to main content

HTML Guide

Free site validation

Find out what web pages on your sites are affected by HTML issues.

Bad value “0” for attribute “step” on element “input”: Zero is not a valid positive floating point number.

The step attribute is a number that specifies the granularity that the value must adhere to.

It sets the stepping interval when clicking up and down spinner buttons, moving a slider left and right on a range, and validating the different date types.

When used, it must be greater than zero.

Example:

<form>
  <!-- Valid values include 1.3, 3.3, 5.3, 7.3, 9.3, 11.3, and so on -->
  <input id="myNumber" name="myNumber" type="number" step="2" min="1.3" />
</form>

Learn more:

Related W3C validator issues