# Semantic HTML

> Pick the HTML tag that says what each part is, like nav, main or button.

**Field:** Software Development  
**Category:** Web Development  
**Also known as:** Semantic Markup, Semantic Elements, HTML5 Semantic Elements

## Think of it like

Think of it like naming the rooms on a house plan. Kitchen and bedroom say more than room one and room two.

## Definition

Semantic HTML means picking the element that says what a part is. Use nav for the menu, main for the main content and footer for the bottom. Use button for a button, not a box made to look like one. The page can look the same either way. But screen readers, search engines and other developers can now tell the parts apart.

## Example

Emma swaps her plain div boxes for header, nav, main and footer. A screen reader can now jump straight to her menu.

## Example code

```html
<nav>
  <a href="/">Home</a>
  <a href="/menu">Menu</a>
</nav>
```

The nav tag tells people and machines that these links are the menu.

## Why it matters

It makes a site usable with a screen reader and a keyboard. It also helps search engines read the page.

## Common mistake

Building every part from div boxes. The page looks right, but its meaning is lost.

## Three principles

- **Say what it is.** Pick the element that names the part.
- **Free help.** Real buttons work with keys by default.
- **Same look.** Meaning changes, the design does not.

## Related terms

- [HTML Element](https://learn.benibix.com/term/development/html-element)
- [HyperText Markup Language (HTML)](https://learn.benibix.com/term/development/html)
- [Landmark Regions](https://learn.benibix.com/term/design/landmark-regions)
- [Heading Structure](https://learn.benibix.com/term/design/heading-structure)
- [Screen Reader](https://learn.benibix.com/term/design/screen-reader)
- [Accessibility (a11y)](https://learn.benibix.com/term/design/accessibility)
- [Accessibility Tree](https://learn.benibix.com/term/design/accessibility-tree)

## Told apart from

- [Semantic HTML vs ARIA Attributes](https://learn.benibix.com/compare/semantic-html-vs-aria): People think ARIA is the way to make a page accessible, and it is not the first step. Semantic HTML comes first: a real button or nav already tells a screen reader what it is. ARIA fills the gaps that no HTML element covers.

## Taught in

- [Semantic HTML Elements](https://learn.benibix.com/learn/development-web/semantic-html-elements): HTML, CSS and JS, 5/14

![The same page layout drawn twice. On the left, every part is a plain div box, and a note says a screen reader sees no parts. On the right, the same parts are named header and nav at the top, main and article in the middle, aside at the side, and footer at the bottom, with a note that each part says what it is.](https://learn.benibix.com/diagrams/dev-semantic-html.svg)

---

Source: https://learn.benibix.com/term/development/semantic-html
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-17
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
