Name

list-style-position

Values:

inside | outside | inherit

Initial value:

outside

Applies to:

Elements whose display value is list-item.

Inherited:

Yes.

Computed value:

As specified.

Description:

This property is used to declare the position of the list marker with respect to the content of the list item. Outside markers are placed some distance from the border edge of the list item, but the distance is not defined in CSS. Inside markers are treated as though they were inline elements inserted at the beginning of the list item’s content.

Examples:

li {list-style-position: outside;}
ol li {list-style-position: inside;}

Supported by:

Firefox, Internet Explorer, Opera, Safari.

Get CSS Pocket Reference, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.