WEB DEVELOPER SITE
HTMLCSSJAVASCRIPTSQLPHPBOOTSTRAPJQUERYANGULARXML
 

HTML <ul> Tag


Example

An unordered HTML list:

<ul>
  <li>app</li>
  <li>c++</li>
  <li>html</li>
</ul>
Try it yourself »

More "Try it Yourself" examples below.


Definition and Usage

The <ul> tag defines an unordered (bulleted) list.

Use the <ul> tag together with the <li> tag to create unordered lists.


Browser Support

Element
<ul> Yes Yes Yes Yes Yes Yes


Differences Between HTML 4.01 and HTML5

The "compact" and "type" attributes are not supported in HTML5.


Attributes

Attribute Value Description
compact compact Not supported in HTML5.
Specifies that the list should render smaller than normal
type disc
square
circle
Not supported in HTML5.
Specifies the kind of marker to use in the list

Default CSS Settings

Most browsers will display the <ul> element with the following default values:

Example

ul {
    display: block;
    list-style-type: disc;
    margin-top: 1em;
    margin-bottom: 1 em;
    margin-left: 0;
    margin-right: 0;
    padding-left: 40px;
}
Try it yourself »