CSS list-style-type

The list-style-type property in CSS is used to define the type of marker or bullet that appears before each list item. This property can be applied to <ul> (unordered lists) and <ol> (ordered lists) elements. There are various values that can be used with list-style-type to customize the appearance of the list items.

Examples:

Result:

ul {
  list-style-type: disc;
}

ol {
  list-style-type: decimal;
}
  
  • Unordered List Item 1
  • Unordered List Item 2
  • Unordered List Item 3
  1. Ordered List Item 1
  2. Ordered List Item 2
  3. Ordered List Item 3

In the example above, the disc value is used for <ul> elements, which displays a filled circle as the bullet point for each list item. The decimal value is used for <ol> elements, which displays numbers as the list items' markers.

Result:

ul {
  list-style-type: square;
}
  
  • List Item 1
  • List Item 2
  • List Item 3

In this example, the square value is used for an <ul> element, which displays square bullets as the markers for each list item. There are many other values that can be used with the list-style-type property to customize the appearance of list items.