HTML Reference ยท Text Content
The <dl> element
Reference for the HTML <dl> element: building description lists of terms and values with <dt> and <dd>, grouping with <div>, examples and technical details.
The <dl> element is a description list: a set of nameโvalue groups. Each group has one or more names in <dt> elements followed by one or more values in <dd> elements. Glossaries are the classic use, but the same shape fits product specs, metadata panels, FAQs and keyโvalue summaries.
<dl> <dt>Weight</dt> <dd>1.2 kg</dd> </dl>
Try it
One name can have several values ("Colors"), and several names can share one value ("Material" and "Lining").
Attributes
This element has no attributes of its own. It accepts the global attributes.
Usage notes
- Direct children are restricted. A
<dl>may only contain<dt>and<dd>groups, or<div>elements that each wrap whole groups, plus script-supporting elements such as<script>and<template>. Don't mix bare groups and<div>wrappers in the same list. - Order matters. In each group the
<dt>elements come first, then the<dd>elements. - Not only for definitions. Any list of names and their values is a good fit. For a plain sequence of items, use
<ul>or<ol>. - Not for dialogue. Don't use a description list to mark up a conversation script.
- Accessibility. Screen readers announce a description list and the number of items in it, so the termโvalue relationship survives without the visual layout.
Technical summary
| Content categories | Flow content; palpable content if it has at least one nameโvalue group |
| Permitted content | Zero or more groups of one or more <dt> followed by one or more <dd>, or one or more <div> elements; either may be mixed with script-supporting elements |
| Tag omission | None; both the start and end tags are required |
| Permitted parents | Any element that accepts flow content |
| Implicit ARIA role | No corresponding role |
| DOM interface | HTMLDListElement |
| Default display | block |
Browser support
Supported in every browser. Wrapping groups in <div> is valid in current HTML and works everywhere.