Description

The HTML <h1> element represents the highest level of heading on a page. There are six levels of headings, from <h1> (most important) to <h6> (least important).

Each page should have exactly one <h1> element that describes the main topic of the page. This is critical for both accessibility and SEO, as search engines use headings to understand the content structure.

CSS Display:block

Syntax

<h1>Main Heading</h1>

Popular Attributes

AttributeDescription
idA unique identifier for the element. Used for CSS styling, JavaScript targeting, and anchor links.
classSpecifies one or more CSS class names for styling the element.

This element also supports global HTML attributes such as class, id, style, data-*, and more.

Examples

Page Heading
<h1>Welcome to HTML Save</h1>
The main heading of a page. There should only be one h1 per page.
Heading Hierarchy
<h1>Main Title</h1> <h2>Subtitle</h2> <h3>Section Heading</h3>
Headings should follow a logical hierarchy — don't skip levels (e.g., don't jump from h1 to h3).

Notes

For SEO, your <h1> should contain your primary keyword and accurately describe the page content. Search engines give significant weight to the h1 tag.

Use only one <h1> per page. Multiple h1 elements can confuse search engines about the primary topic of the page.

Related Tags

Last updated: 7th April 2026