HTML <ul> Unordered List Tag Reference

The ul HTML tag creates an unordered list of items.

In normal text, an unordered list will appear as a bulletd list, but they can take many different forms.

The <ul> HTML/xHTML tag

The <ul> tag defines an unordered list:

  • A list, indicating that there should be a consecutive sequence of more than one item, each item having some common property or equivlence.
  • Unordered tells us that the order of the items that comprise the list does not carry much significance.

In normal text, in a visual browser, a <ul> will by default appear as a bulleted list, whereas an ordered list (<ol>) tag will create items bearing numbers or letters to show the significant order.

When to use the <ul> tag (semantic use)

Use <ul>s whenever you have any sequence of more than one related HTML elements.

Common appropriate applications of unordered lists include:

  • Bulleted lists in normal text content.
  • Groups of navigation items, which may be in a horizontal list (such as in our footer navigation), or even more graphical links such as tabs.
(I would not use unordered lists for inline comma-separated lists within normal text, as these would not naturally be displayed as a standalone collection of bulleted items.)

<ul> is valid in all current versions of HTML and xHTML, and it should always have a closing </ul> tag.

It may contain only <li></li> (list item) tags, which in turn can contain other HTML tags and content.

Example

This is a simple example.

<ul id="womblesList" class="standard">
<li>Tomsk</li>
<li>Orinocho</li>
<li>Great Uncle Bulgaria</li>
</ul>

Alternatives to the <ul> tag

You may also consider using:

Ordered lists
Use an <ol> tag where the order of items is significant, e.g. listing events in time order, or race results.
Definition lists
Use a <dl> where the list is comprised entirely of pairs of elements, with a title or name together with a description or definition.