Sub topic 6
Lists, figures, quotes and addresses
This chapter covers the grouping elements that give structure to blocks of content: lists, figure, blockquote and address. It assumes you know basic HTML syntax, including tags, attributes and nesting. It also assumes you can open your browser's developer tools.
Why grouping elements matter
A group of related items is easy to see on screen. Assistive technology cannot see the screen. It relies on the markup to learn that items belong together. A screen reader announces "list, 3 items" before reading a real list. It says nothing of the kind for three paragraphs that merely look like bullets.
Lists
HTML has three list types. Pick the one that matches the content.
| Element | Use it when | Children |
|---|---|---|
| `ul` | Order does not matter | `li` |
| `ol` | Order or ranking matters | `li` |
| `dl` | Terms paired with descriptions | `dt`, `dd` |
<ol>
<li>Preheat the oven.</li>
<li>Mix the batter.</li>
<li>Bake for 30 minutes.</li>
</ol>
<dl>
<dt>Prep time</dt>
<dd>15 minutes</dd>
<dt>Servings</dt>
<dd>4</dd>
</dl>The navigation in an earlier chapter used ul inside nav. Navigation menus are lists of links, so this is the correct choice. Only li elements may be direct children of ul and ol. Do not put a bare a or div directly inside them.
Lists are not only for bullets. You can remove the markers with CSS (list-style: none) and keep the meaning. Be aware that some screen reader and browser combinations stop announcing a list when its markers are removed. If the list matters, add role="list" to the ul.
Figures and captions
figure wraps self-contained content that is referenced from the main text. This can be an image, a diagram, a code sample or a chart. figcaption gives it a caption.
<figure>
<img src="chart.png" alt="Bar chart: sales rose each quarter of 2025">
<figcaption>Quarterly sales, 2025</figcaption>
</figure>The figcaption becomes the accessible name of the figure. It does not replace the alt text. The caption says what the image is. The alt text describes what it shows for someone who cannot see it. Do not wrap every image in a figure. A decorative or inline image that is part of a sentence does not need one.
Quotations
Use blockquote for a longer quotation taken from another source. Use cite for the URL of that source. Use the inline q element for short quotations inside a sentence.
<blockquote cite="https://example.com/source">
<p>Markup should describe meaning.</p>
</blockquote>Browsers do not display the cite attribute. To show the source to readers, put it in visible text, for example in a figcaption or a footer inside the blockquote. Do not use blockquote just to indent text. That is a job for CSS.
Contact details with address
address marks contact information for the nearest article or body ancestor. It is not for any postal address you happen to mention.
<footer>
<address>
Questions? Write to <a href="mailto:[email protected]">[email protected]</a>.
</address>
</footer>Checking your work
Open devtools and inspect a list. In the accessibility pane, look for the list role and its listitem children. If you see only generic nodes, the markup is not doing its job.
Exercise
A site's footer shows three links in a row, styled with CSS to look like a horizontal bar. Which elements should you use, and why does it matter for a screen reader user?
Show answer
Put the links in a ul with an li and an a for each one, inside the footer or a nav. Then the screen reader announces a list of three items, so the user knows how many links there are and where the group ends. Separate a elements or a div would hide that grouping.
Exercise
You quote a paragraph from a report and want to credit it. Which element holds the quotation, and where should the visible credit go?
Show answer
Use blockquote for the quotation. Put the credit in visible text, such as a figcaption if the quote is in a figure, because the cite attribute is not shown to readers.