MDN self-hosted library · e01.org

HTMLOListElement: start property

HTML DOM

Open notebook · 2 cells web-api-instance-property upstream source

HTML DOM

The start property of the HTMLOListElement interface indicates starting value of the ordered list, with default value of 1.

It reflects the start attribute of the ol element.

[!NOTE] The start property value is independent of the HTMLOListElement.type property; it is always numeric, even when type is letters or Roman numerals.

Value

A long value.

Examples

HTML

<ol id="order-list">
  <li>Fee</li>
  <li>Fi</li>
  <li>Fo</li>
  <li>Fum</li>
</ol>

JavaScript

const olElement = document.querySelector("#order-list");
console.log(olElement.start); // Output: "1"
olElement.start = "11";
console.log(olElement.start); // Output: "11"

Result

400

Specifications

Browser compatibility