How to create HTML lists without bullets

Learn how to create an HTML unordered list without bullets

Posted on August 10, 2021


The HTML <ul> tag is used to create an unordered list of text.

By default, browsers will render the <ul> elements using bullet points.

The following example:

<body>
  <h1>Web technologies</h1>
  <ul>
    <li>HTML</li>
    <li>CSS</li>
    <li>JavaScript</li>
  </ul>
</body>

Will produce the following output:

If you want to render the list <li> elements above without the bullet points, you need to add the list-style-type:none style property to the <ul> element:

<body>
  <h1>Web technologies</h1>
  <ul style="list-style-type:none;">
    <li>HTML</li>
    <li>CSS</li>
    <li>JavaScript</li>
  </ul>
</body>

The <ul> tag also has a default padding-inline-start style with the value of 40px that gives space for the list style. Since you’re not rendering any list style, you may also want to remove the padding.

The padding-inline-start style is not supported by Internet Explorer. If you need to support Internet Explorer and older browsers, you need to replace padding-inline-start with padding-left style.

The padding-left style will override the padding-inline-start style used by modern browsers and the default padding-left:40px style for <ul> implemented by Internet Explorer:

<ul style="list-style-type:none; padding-left: 0px"></ul>

You can extract the styles as a CSS class rule to reuse those styles in many <ul> tags:

ul.list-none {
  list-style-type: none;
  padding-left: 0px;
}

Next, just apply the class style-none to your <ul> tags to render the list without bullet points:

<body>
  <h1>Web technologies</h1>
  <ul class="list-none">
    <li>HTML</li>
    <li>CSS</li>
    <li>JavaScript</li>
  </ul>
</body>

And that’s how you can create HTML lists without bullets 😉

Related articles:

Level up your programming skills

I'm sending out an occasional email with the latest programming tutorials. Drop your email in the box below and I'll send new stuff straight into your inbox!

No spam. Unsubscribe anytime.