Skip to content

24 Semantic Terms Web Pros Should Know

Ninety-seven percent of the web is broken. Let that sink in a bit… OK, now that sentence might be an exaggeration but the web is currently in very bad shape. According to an annual web accessibility study, 96.8% of home pages had detected WCAG 2 failures out of the top million home pages that were analyzed. Common issues found on these pages were related to incorrect semantics or the lack of semantics. How did this happen? I believe that is largely due to the fact that most web professionals—designers, developers, and content creators—did not receive proper education (or told to care) about web semantics or semantic HTML, which is the foundation for creating accessible websites.

In this article, I will give a quick overview of 24 important semantic terms to know and understand. I hope you learn something and go on to create better websites, or usable websites that do not exclude anyone at the very least. Happy holidays!

Table of Contents

Details
  1. Landmarks
  2. Main
  3. Aside
  4. Footer
  5. Header
  6. Heading
  7. Image
  8. Link
  9. Button
  10. Navigation
  11. Menu
  12. Select Input
  13. Disclosure Widget
  14. Dialog
  15. List
  16. Description List
  17. Form
  18. Input
  19. Label
  20. Fieldset
  21. Legend
  22. Table
  23. Data Cell
  24. Header Cell

Landmarks

Landmarks are special regions of a page. They give screen readers and other assistive technologies the ability to jump around, therefore enhancing the navigation experience for the user.

Header Main Aside Footer

Main

A main is a landmark that indicates main content of a page.

HTML tag: <main>

Aside

An aside is a landmark that indicates complimentary content that indirectly relates to the main.

HTML tag: <aside>

A footer is a landmark that indicates footer content of a page—eg. copyright data, related links, etc.

HTML tag: <footer>

A header is a landmark that indicates header content of a page—eg. logo, navigation, search, etc.

HTML tag: <header>

Heading

A heading describes a section of content. There are 6 levels. Level 1 is usually used for the title of a page. Subsequent headings should not skip levels.

HTML tags: <h1>, <h2>, <h3>, <h4>, <h5>, <h6>

This is a level 1 heading

This is a level 2 heading

This is a level 3 heading

This is a level 4 heading

This is a level 5 heading
This is a level 6 heading

Image

An image embeds a graphic, whether it is raster based (JPG, GIF, PNG, etc.) or vector based (SVG). Alternative text should be provided for images that are essential information.

HTML tag: <img alt="...">

Gray placeholder

A link helps the user to navigate to another page or another section of the same page. The enter key triggers it. A link is not a button.

HTML tag: <a href="...">

This is a link

Button

A button helps the user to perform a function—eg. submit a form, expand/collapse a block of content, etc. The enter or space key triggers it. A button is not a link.

HTML tag: <button type="...">

A navigation is a list of links—eg. site navigation, table of contents, etc. A navigation is not a menu.

HTML tag: <nav>

A menu is a list of buttons. It is usually hidden until a trigger expands it—eg. right click on an interface or tap on an expand button. A menu is not a navigation.

HTML tags: <ul role="menu"> and <li role="menuitem">

  • This is a menu:

Select Input

A select input expands a list of options. It is usually used within the context of a form. The space key triggers it. A select input is neither a menu or navigation.

HTML tags: <select> and <option>

Disclosure Widget

A disclosure widget expands hidden content. It is usually used for secondary information that can be displayed on the user’s demand. The enter or space key triggers it. A disclosure widget is neither a menu or navigation.

HTML tags: <details> and <summary>

This is a disclosure widget

Now open.

Dialog

A dialog is a content container that overlays the page content. It is not to be confused with the word modal. Modal is a state: a state that excludes all interaction with elements outside the dialog. The esc key triggers the close of a dialog. A dialog is neither a menu or navigation.

HTML tag: <dialog>

This is the dialog heading

This is the dialog content.

List

A list contains a list of items. It can be ordered or unordered.

HTML tags: <ul> and <li>, <ol> and <li>

  • This is a list item
  • This is a list item
  • This is a list item
  1. This is a list item
  2. This is a list item
  3. This is a list item

Description List

A description list is a list of groups of terms. Each group contains a term and its description. It is commonly used in glossary pages.

HTML tags: <dl> and <dt> and <dd>

This is a term
This is its description.
This is a term
This is its description.
This is a term
This is its description.

Form

A form contains controls for submitting information.

HTML tag: <form>

  • Legend for the fieldset

ℹī¸ Input 1 and input 2 are related, therefore grouped together in a fieldset; checkbox 1 and checkbox 2 are unrelated.

Input

An input accepts value to be submitted via a form. There are different types of inputs—eg. text, number, email, checkbox, radio, textarea, select, etc. An input must be used inside a form.

HTML tags: <input type="...">, <textarea>, <select>

Label

A label defines the purpose of an input. A label must be used inside a form.

HTML tag: <label>

Fieldset

A fieldset is a group of related inputs—eg. a first name input and a last name input grouped together by a fieldset called Personal Info. A fieldset must be used inside a form.

HTML tag: <fieldset>

Legend

A legend defines the purpose of a fieldset. A legend must be used inside a fieldset in a form.

HTML tag: <legend>

Table

A table contains tabular content displayed in a grid. A table is not to be used for layouts.

HTML tag: <table>

This is a header cell This is a header cell This is a header cell
This is a data cell This is a data cell This is a data cell
This is a data cell This is a data cell This is a data cell
This is a data cell This is a data cell This is a data cell

Data Cell

A data cell is a regular cell in a table. A data cell must be used inside a table.

HTML tag: <td>

Header Cell

A header cell is a cell in a table that can act as a column header or row header. A header cell must be used inside a table.

HTML tag: <th>