H1 to H6: how header tags work
Headings run from <h1>, the highest level, to <h6>, the lowest. The H1 names the page, H2s name its main sections and H3s the parts inside those. MDN's HTML reference advises one H1 per page, and says not to skip levels, because people using screen readers often move around a page by jumping from heading to heading.
Does the H1 still matter for SEO?
Yes, in two plain ways. Google's documentation lists the main visible title and heading elements such as the H1 among the sources it uses to write a page's title link in results, and suggests putting the page's title text in the first visible H1. And a visitor checks the H1 first to see whether they landed in the right place.
What doesn't matter is the count or the order. Google's SEO starter guide says heading order makes no difference to Google Search, and that there is no ideal number of headings on a page.
How to write one
Google publishes no length limit. What works:
- Say what the page is, in the words a searcher would use.
- Keep it close to the title tag, so Google has no reason to pick another headline.
- Use one H1 for the page's name, and H2s for its sections.
- Make it visible text, not words inside an image.
- Don't use a heading tag to make text bigger; MDN says to style text with CSS instead.