Values can appear in any order. Omitted parts fall back to disc, outside, and none. It is inherited. Nested lists often reset the type unless you set inherit.
Baseline widely available.
Not deprecated. Common keywords like disc, square, decimal, inside, outside, and none are safe. Some exotic counter styles vary by browser.
Target the list. Styles on ul apply to its list items.
One keyword.square sets list-style-type; position stays outside.
Fast change. Swap disc, circle, or decimal the same way.
Shorthand win. No need to write the longhand for a simple marker swap.
Example 2 — Type and Position
Place the marker inside the content box.
CSS
<style>
ul {
list-style: square inside;
}
</style>
<ul>
<li>Short item</li>
<li>A longer item that wraps under the marker when space is tight.</li>
</ul>
Hide markers.list-style: none removes the bullet or number.
Reset padding. Many browsers indent lists; padding-left: 0 aligns the text.
Keep semantics.role="list" helps Safari announce the list when markers are none.
Common pattern. Navigation menus often use this combo.
Edge Cases & Pitfalls
Markers look simple until nesting or accessibility gets involved.
nest
Nested lists reset the type
Browsers set default types on nested ul/ol. Use list-style: inherit on nested lists to keep your custom marker.
a11y
none and Safari VoiceOver
Safari may not expose a list with list-style: none as a list. Add role="list" when that matters.
image
Type is the image fallback
If list-style-image fails to load, the type marker still shows. Keep a sensible type when you use an image.
order
Value order is flexible
square inside and inside square both work. The browser maps each token to the matching longhand.
display
Needs list items
Markers apply to list items. A plain div needs display: list-item to show them.
Compatibility
Browser Support
list-style is a browser CSS shorthand for list markers. Node.js, Deno, and Bun do not apply it.
✓ Baseline · Widely available
list-style
Common types, inside/outside, none, and images are widely supported. Some specialized counter styles vary by browser.
100%Common values
Google ChromeAll versions
Full support
Mozilla FirefoxAll versions
Full support
Apple SafariAll versions
Full support
Microsoft EdgeAll versions
Full support
OperaAll versions
Full support
Samsung InternetAll versions
Full support
Internet ExplorerAll versions
Full support
list-styleWidely supported
Bottom line: Safe for everyday list styling. Prefer standard types for study. It is not a runtime API.
Remember
Key Takeaways
Role: shorthand for type, position, and image of list markers.
Defaults:disc / outside / none.
none: hide markers; consider role="list" for Safari.
Nested lists: use inherit if you want the same type.
One line:list-style is the quick way to set list markers — type, position, and optional image in one go.
Frequently Asked Questions
It is a shorthand for list-style-type, list-style-position, and list-style-image. One declaration can set the marker kind, where it sits, and an optional image.
The longhands default to disc, outside, and none — a filled circle marker outside the content, with no custom image.
It hides the marker. Useful for nav menus built with ul. In Safari, also consider role="list" so the list stays announced as a list.
Not always. User-agent styles reset list-style-type on nested lists. Set list-style: inherit on nested lists if you want the same marker.
Yes. Values can appear in any order, such as list-style: square inside.
It is Baseline and widely available for common types, inside/outside, none, and images. It is a browser CSS property, not a Node.js feature.