Preferences

Privacy is important to us, so you have the option of disabling certain types of storage that may not be necessary for the basic functioning of the website. Blocking categories may impact your experience on the website. More information (Cookie Policy)

Semantic HTML: Which Tags to Use, Why They Matter for Accessibility, Google and AI

Semantic HTML explained: what each structural tag means, how it helps screen readers, Google and AI assistants read your page, and the mistakes to fix first.

Published on
18/10/2026
Updated on
18/10/2026
Reading time
9 min
Semantic HTML: Which Tags to Use, Why They Matter for Accessibility, Google and AI

Tools

On this page

In short

semantic HTML means using tags that describe what content is (<header>, <nav>, <main>, <article>, <section>, <aside>, <footer>, ordered headings, <figure>, <time>, <table>) instead of generic <div> and <span> everywhere. It lets screen readers navigate by landmarks, helps Google identify the main content of a page, and makes it easier for AI assistants to extract a clean, self-contained passage. It costs nothing at build time and is hard to add later.

Want to go further? Ask

Quick quiz

Who should fix the technical side of your site?

Question 1 of 425%
What is happening today?

A browser displays a <div> and a <nav> the same way. The difference lies in meaning: semantic HTML tells every program reading the page what role each block plays. MDN defines it as using elements according to their meaning, not their default appearance. Search engines, assistive technologies and the crawlers that feed AI models all benefit from that meaning.

What are the main semantic HTML tags?

The HTML standard defines dozens of elements. These are the ones that structure almost every content page:

TagRoleTypical use
<header>Introductory content of the page or of a sectionLogo, site name, title of an article with author and date
<nav>Block of major navigation linksMain menu, breadcrumb, table of contents
<main>Unique main content of the page (one visible per page)Everything except header, menus, sidebars and footer
<article>Self-contained content that makes sense on its ownBlog post, product card, comment, news item
<section>Thematic group of content, normally with a headingA chapter of a guide, a block of a landing page
<aside>Content related to the main content but separate from itSidebar, related links, glossary box
<footer>Closing information of the page or of a sectionLegal links, contact, author note
<h1> to <h6>Heading hierarchyOne <h1> for the page topic, <h2> for sections, <h3> for subsections
<figure> and <figcaption>Illustration with its captionChart, photo, diagram with a caption
<time>Date or time in a machine-readable formPublication and update dates
<table>, <th>, <caption>Tabular data with headersComparisons, prices, specifications

Text-level tags also carry meaning: <strong> for importance, <em> for emphasis, <blockquote> and <cite> for quotations, <ul> and <ol> for lists, <a> for links and <button> for actions.

Why does semantic HTML matter for accessibility?

Screen readers build a map of the page from its tags. The landmarks <header>, <nav>, <main>, <aside> and <footer> let a user jump straight to the menu or the content, and the heading list works as a table of contents. The W3C accessibility tutorials on page structure recommend these regions and a logical heading order for that reason.

A clickable <div> is invisible to the keyboard and silent for a screen reader unless you rebuild by hand what a native <button> gives you for free. Native elements come with their role, keyboard focus and expected behavior. In many countries, accessibility of public and commercial websites is also a legal requirement, which makes clean markup a compliance matter as well.

Does semantic HTML help SEO?

Google has never presented semantic tags as a direct ranking factor, and a page in plain <div> can rank. The value is indirect but real:

  • Main content detection: <main> and <article> help separate the text that matters from menus, sidebars and footers that repeat on every page.
  • Topic structure: an ordered heading hierarchy shows what the page covers and how its parts relate, which supports relevance for long-tail queries.
  • Rich understanding of elements: real tables, lists and dates are easier to read than visual imitations built with styled blocks.
  • Consistency with structured data: semantic markup and JSON-LD describe the same page from two angles. Our entry on structured content shows how they fit together.

Semantic HTML is part of technical SEO in the same way as clean URLs or fast pages: a foundation that lets your content be read correctly.

How do AI assistants use page structure?

ChatGPT, Gemini, Perplexity and Google AI Overviews do not cite whole pages: they select passages. The crawlers that fetch your page usually strip navigation and boilerplate, then cut the text into chunks. A section that opens with a clear <h2>, answers its question in the first paragraph and stays within one <section> produces a clean chunk. The same content spread across nested <div>, with headings faked by bold text, produces fragments mixed with menu items. Our guide to content chunking explains how to write sections that survive this cut.

Does accessibility help SEO?

Yes, but indirectly. Most accessibility fixes are also SEO fixes: descriptive alt text, real headings, real links and real buttons. Google calls alt text "the most important attribute" for giving an image metadata, and it reads that text with the page content to work out what the image shows. If a screen reader can follow your page, a crawler can usually follow it too.

Accessibility asks for more than that overlap. Keyboard focus, color contrast, labels on form fields and captions on video all matter to users who cannot use a mouse or cannot see colors well. Crawlers do not test these for you, so check them by hand: tab through the page with the keyboard, then zoom the text to 200% and make sure nothing breaks.

Alt text does two jobs

Alt text is read aloud when an image is not seen. It also tells search engines what the image is about. Describe what the image shows and why it is on the page, in one short phrase. Leave a keyword out of it unless it fits the description. Google warns against keyword stuffing in alt text because it makes the page worse for users.

<!-- Stuffed: a keyword list that says nothing -->
<img src="/img/chart-07.png" alt="semantic html seo accessibility tags">

<!-- Useful: says what the image shows -->
<img src="/img/chart-07.png" alt="Bar chart of heading levels on a well-structured article">

<!-- Decorative: empty alt, so screen readers skip it -->
<img src="/img/divider.png" alt="">
Accessibility needMarkup that meets itSEO effect
Jump to the contentOne <main> with one <h1>Clear main content for crawlers
Understand an imageDescriptive alt textImage meaning and image search
Follow a link or press a button<a href> and <button>Links that crawlers can follow
Scan the page by headingsHeadings in order, no skipped levelsA visible topic outline

Google's image guidance on image SEO best practices asks you to consider the accessibility of your alt text, following the W3C guidelines.

Tip

Check one URL twice: first its heading outline with the heading structure analyzer, then its missing or weak alt text with the alt text checker. For the full rules on writing alt text, read our alt text guide.

What does a well-structured article page look like?

Here is the skeleton of a blog article, described tag by tag:

1. <header> contains the logo and a <nav> with the main menu. This block repeats on every page, so crawlers learn to ignore it.

2. <main> opens right after. It holds a single <article>, the content you want indexed and quoted.

3. Inside the <article>, a <header> groups the <h1> (the page topic), the author name and a <time datetime="2026-10-18"> element with the publication date in a machine-readable format.

4. Each part of the article is a <section> that starts with an <h2> phrased as the question it answers, followed by <p> paragraphs, <ul> lists or a <table> with <th> headers.

5. A chart goes in a <figure> with an <img> carrying a descriptive alt text and a <figcaption> that states what the chart shows.

6. Related links go in an <aside>, outside the main flow of the article.

7. A <footer> closes the page with legal and contact links.

With this skeleton, a screen reader user can jump to the content in one keystroke, Google sees one main article with a clear outline, and an AI crawler can lift any <section> as a standalone answer.

Which semantic HTML mistakes are the most common?

  • Div everywhere: page builders often output layers of <div> with no landmarks. Check that at least <main> exists and wraps the content.
  • Skipped or misused headings: jumping from <h2> to <h4>, using headings to make text big, or using bold paragraphs as fake headings. Choose the level by structure, then style it with CSS.
  • Several competing <h1>: HTML allows it, but a single <h1> describing the page topic stays the clearest signal for users and search engines.
  • Clickable <div> and <span>: use <a> for navigation and <button> for actions.
  • Layout tables and fake tables: tables are for data; data shown in styled blocks loses its row and column relations.
  • Images of text: a heading or a price inside an image cannot be read by a crawler or a screen reader.
  • Dates in plain text only: add <time> with a datetime attribute so the date is unambiguous.

What is a heading hierarchy, and how do you build a semantic one?

A heading hierarchy is the nested order of your <h1> to <h6> tags. It is semantic when each level shows where its section sits in the page: <h1> names the topic, <h2> opens a main part, and <h3> splits that part into subsections. Pick each level from the structure of your content, then adjust the size with CSS.

Think of your headings as a table of contents. Extract them alone, and the list should read as a complete outline of the page.

Build the outline before you style it

Start with the content. List the topics in order, then give each one a level:

  • One <h1> for the page topic.
  • An <h2> for each main part, phrased as the question or task it answers.
  • An <h3> only inside an <h2>, for a point that belongs to that part.

If a part fits under no level above it, the outline needs a new <h2>. A bigger font will not fix it.

Mistakes that break the hierarchy

ProblemWhat it does to the outlineFix
An <h2> followed by an <h4>Skips a level, so the structure looks brokenUse an <h3> and adjust its size in CSS
A bold paragraph used as a titleLooks like a section to a sighted reader, but no tool reads it as oneReplace it with a real <h2> or <h3>
A heading chosen for its sizeLevels no longer match the contentChoose the level by position, then style it
An empty headingShows up as a blank entry in screen reader navigationWrite a label or remove the tag

Multiple <h1> tags are valid HTML, but a single one keeps the page topic clear. Our H1 tag guide covers the details.

Check the hierarchy of your own pages

Copy the headings in order and read them alone. Ask whether they tell the story of the page. Then check that no level is skipped and that every <h3> sits under an <h2>. Use the same template for each post, such as the one in our guide to formatting a blog post, so the outline stays consistent. Plan the levels before you write with a content outline.

How do you audit the semantic structure of a page?

Three quick checks cover most issues. First, display the heading outline of the page and read it alone: it should tell the story of the content. Second, look for <main>, <nav> and <article> in the source code. Third, navigate the page with the keyboard only and see whether every link and button is reachable. Our on-page SEO audit lists heading and markup issues for any URL, and the free Sorank Chrome extension shows the heading structure of the page you are viewing.

Use each tag for what it means: one <main>, one <h1>, ordered sections and real tables give people, Google and AI the same clear map of your page. Once the structure is clean, the content still has to be written and published regularly: Sorank writes and publishes optimized articles for Google and AI on autopilot.

Frequently asked questions

Is semantic HTML a Google ranking factor?

Google has not described semantic tags as a direct ranking factor, and pages built with generic div elements can rank. Semantic markup helps Google identify the main content and the outline of a page, which supports relevance. Its effect is indirect, through better understanding of the page.

How many h1 tags should a page have?

The HTML standard does not forbid several h1 elements, and Google says it can handle them. Still, one h1 that states the topic of the page, followed by ordered h2 and h3 headings, is the clearest structure for users, screen readers and search engines.

What is the difference between section and article?

An article is content that makes sense on its own and could be shared or syndicated separately, such as a blog post or a product card. A section is a thematic part of a larger whole, normally introduced by a heading. An article can contain sections, and a section can contain several articles.

Get your content plan for 30 days for free

We analyse your competitors, your website and your AI visibility to create a tailored content plan for free.

Our free SEO tools

See all our free tools

Get your content plan for 30 days for free

We analyse your competitors, your website and your AI visibility to create a tailored content plan for free.

Man with dark hair and beard wearing a light brown shirt speaks in front of a microphone on a podcast or recording setup.Portrait of a man with short dark hair wearing a white shirt and dark jacket, looking directly at the camera with a neutral expression.Man with short dark hair, beard, and clear glasses wearing a black t-shirt with a white circular logo, standing in front of a stone wall.Celio fabianoSmiling young woman with long brown hair wearing a red top and necklace, outdoors in a tree-filled background.Profile photo of Xavier Breull, Sorank customer
Google
Solid yellow five-pointed star icon on transparent background.Solid yellow five-pointed star icon on transparent background.Solid yellow five-pointed star icon on transparent background.Solid yellow five-pointed star icon on transparent background.Solid yellow five-pointed star icon on transparent background.
5/5
+5,000
users

Testimonials from ambitious founders

0 to 10000 visitors in 5 months

Celio Fabianomonrobotlavevitre.frGoogleE-commerce

0 to 5000 visits in 8 months

Thibault BMsorank.comGoogleSoftware

0 to 1104 clicks in 4 months

Dominiqueflight-sensations-idf.comGoogleLeisure and aviation

0 to 163 clicks in 6 months

Coworking Pariscoworking-paris.frGoogleOffice broker

x92 clicks in 7 months

Guide Zanzibarguidezanzibar.comGoogleTravel