Header tags (H1–H6)
What are header tags?
Header tags are the six HTML heading elements, <h1> to <h6>, used to give a page a structure of titles and subtitles. H1 is the main heading, H2s mark the main sections, H3s subsections within them, and so on. They help readers scan, help screen reader users navigate, and help search engines understand what each part of a page covers.
Headings should reflect the content’s outline, not visual style. Using an H2 just because you want bigger text, or bold paragraphs instead of real headings, makes the structure harder to read for assistive technology and search engines. Style headings with CSS and choose the level by meaning.
The levels should nest in order: an H3 belongs under an H2, not straight under the H1. See heading hierarchy for how to keep the outline clean. The H1 is covered in its own entry, the H1 tag.
Why header tags matter for SEO
Clear subheadings help Google identify which part of a page answers a specific question, which can help with featured snippets and passage-level ranking. They also make long pages easier to read, so visitors find their answer and stay.
Headings are a natural place for secondary keywords and question phrasings, as long as they read well.
How to use header tags
- Use one H1 for the page’s main topic.
- Use H2s for each major section and H3s for points within a section.
- Make headings descriptive: a reader should understand the section from the heading alone.
- Phrase some headings as the questions people search, then answer right below.
- Don’t use headings for styling, navigation labels or boilerplate.
Header tags example
<h1>Sourdough starter guide</h1>
<h2>What you need</h2>
<h2>How to make a starter</h2>
<h3>Day 1: mix flour and water</h3>
<h3>Days 2 to 7: feed daily</h3>
<h2>Common problems</h2>Header tags FAQ
Do header tags help SEO?
Yes, by making the page’s topic and structure clear to search engines and readers. They are a helpful signal, not a lever you can pull by stuffing keywords into them.
How many H2s should a page have?
As many as the content has main sections. There is no ideal number.
Related SEO terms
An H1 tag is the main heading of a web page. It tells readers and search engines what the page is about, and most pages should have one.
Heading hierarchy is the logical order of H1 to H6 headings on a page, so sections nest correctly and readers and crawlers can follow the outline.
A featured snippet is a highlighted extract from a web page shown near the top of Google’s results to answer the query directly, with a link to the source.
Readability is how easy a text is to read and understand, shaped by sentence length, word choice, structure and layout.
On-page SEO is optimising the content and HTML of each page, such as text, title tag, headings, images and internal links, to rank and earn clicks.