Lists & Counters in CSS

From the CSS cheat sheet ยท Typography ยท verified Jul 2026

Lists & Counters

Style ordered/unordered lists, custom markers, and CSS counters

css
/* Remove default list styles */
ul { list-style: none; padding: 0; }

/* Custom markers */
li::marker { color: #3b82f6; font-size: 1.2em; }
ul { list-style-type: "โ†’ "; }
๐Ÿ’ก list-style: none + padding: 0 is the standard reset for navigation menus
โšก ::marker pseudo-element lets you style bullet/number color and size independently
๐Ÿ“Œ CSS counters auto-number without using <ol> โ€” great for steps, figures, and headings
๐ŸŸข Custom string list-style-type accepts any string: emojis, arrows, check marks
listsmarkerscounters

More CSS tasks

Back to the full CSS cheat sheet