Semantic HTML
Semantic HTML is code that describes what content actually is, not just how it looks — the foundation both accessibility and search engines depend on.
Glossary
Semantic HTML means using code elements that describe what content actually is — a heading, a list, a button, an article — rather than generic containers styled only to look that way. The markup lets a browser, a screen reader or a search engine understand a page’s structure.
Semantic HTML code and CSS: why “looks right” is not the same as “is correct”
A heading styled with large, bold text using only CSS, without the underlying heading element, looks identical to a genuine heading to a sighted visitor. But a screen reader has no way to recognise it as a heading. A visitor navigating a page by jumping between headings will skip straight past it as if it were not there at all. This is one of the hardest accessibility failures to notice, precisely because it is invisible to anyone not using assistive technology.
Why it matters to more than accessibility
Search engines and other automated tools rely on semantic structure to understand what a page is about and how its content is organised. A correctly marked-up heading hierarchy, list and article structure gives these tools a genuine signal about content organisation that generic, undifferentiated markup does not provide.
What it looks like in practice
Semantic HTML in practice means four habits: real heading elements, genuine list elements, a button element for actions, and a heading hierarchy with no skipped levels. Each uses the element that matches the content rather than plain text styled to look the part — a heading element for a heading, and a button element for something that triggers an action rather than navigates.
The semantic HTML elements themselves — header, nav, main, article, section, aside, footer — and what div and span tags they replace
HTML5 added seven semantic elements so a page need not be built entirely from meaningless <div> and <span> containers: <header>, <nav>, <main>, <article>, <section>, <aside> and <footer>. <header> holds introductory content, <nav> a block of navigation links, <main> the primary content of the page, <article> a self-contained piece such as a blog post, <section> a thematic grouping within the page, <aside> tangential content such as a sidebar, and <footer> closing content. A <div> or <span> still has a legitimate job — wrapping something purely for styling, with no meaning to convey — but a page built entirely from <div> tags, where a <header>, <nav> or <article> element is accurate, is the generic-container failure this concept exists to name. The code itself, not the semantic tags in isolation, is what a screen reader or search engine reads.
What to do next
For where this foundational build discipline sits in a project, web development services covers where it is scoped as part of a build’s underlying code quality. The viewport meta tag is a second piece of invisible markup a build gets right or silently fails; the glossary defines the related terms.