HTML <li> value attribute

Definition and usage

value Attribute specifies the number of the list item. The next list item will start ascending from this number.

This value must be a number and can only be used in an ordered list (<ol>in the parentheses.

Example

Use the value attribute in an ordered list:

<ol>
  <li value="100">Coffee</li>
  <li>Tea</li>
  <li>Milk</li>
  <li>Pure water</li>
  <li>Juice</li>
  <li>Beer</li>
</ol>

Try it yourself

Syntax

<li value="number">

Attribute value

Value Description
number Specify the value of the list item.

Browser support

Chrome Edge Firefox Safari Opera
Chrome Edge Firefox Safari Opera
Support Support Support Support Support