HTML header tag h1 is used for specifying heading level 1. There are 6 levels of headings (h1h6) with h1 the most important and h6 the least important.

Browsers are supported various headings in different sizes – with h1 being the largest and h6 being the smallest.

Example

<!DOCTYPE html>
<html lang=”en”>
<head>
<meta charset=”UTF-8″>
<title> HTML Heading Tag </title>
</head>
<body>
<h1> This is Heading 1 </h1>
<h2> This is Heading 2 </h2>
<h3> This is Heading 3 </h3>
<h4> This is Heading 4 </h4>
<h5> This is Heading 5 </h5>
<h6> This is Heading 6 </h6>
</body>
</html>

Output

This is Heading 1

This is Heading 2

This is Heading 3

This is Heading 4

This is Heading 5
This is Heading 6

Note : There is a special tag for specifying headings in HTML. There are 6 levels of headings in HTML ranging from h1 for the most important Tag and h6 tag for the least important. Don’t use headings to make text <big> or <strong>.

Importance of Headings

  • HTML heading provide useful information by identifying essential subjects and the document’s structure; therefore, they should be properly optimized to increase user engagement.
  • To make your text look BIG or bold, don’t use headings. Use them just to highlight your document’s heading and to display the document’s structure.Since search engines, such as Google, use headings to index the structure and content of the web pages so use them very wisely in your webpage.
  • Use the <h1> headings as main headings of your web page, followed by the <h2> headings, then the less important <h3> headings, and so on.

Leave a Comment

Your email address will not be published.