HTML & CSS Basics
chapter 03 · Text Content & Semanticsstep 1 / 10 mode · learn
Headings and hierarchy

Why heading levels exist

HTML gives you six heading levels: <h1> through <h6>. They are not about size — they are about outline. <h1> is the single main title of the page. <h2> starts a major section. <h3> a subsection of that. And so on. Screen readers, search engines, and future you all use this outline to understand the page. Skipping levels (h1 → h4) breaks that outline.

why it matters

Google reads your headings to understand what the page is about. Blind users tab through them to navigate. Getting hierarchy right is one of the highest-leverage things a beginner can learn.