Create headings in HTML

Create Headings in HTML

Headings are very important in HTML documents. Search engines use your headings to index the structure and the content of your pages, headings provide structure, and visitors skim your pages by headings. Use HTML headings for headings only. You should not use them to make text bold or big. If you want to know how to make text bold in HTML, click here. If you want to know how you can make text bigger or smaller, click here. In the following tutorial, we gladly help you to create headings in HTML.

Headings in HTML

HTML provides six heading commands. <h1> headings are the largest main headings and <h6> headings are the smallest. Use the following tags to create headings in HTML:

<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>

Here is an example of the the relative sizes of the HTML headings:

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 that some browsers add heading 7 and heading 8, but that these are not part of the recognized HTML standard.
Note that browsers automatically add an empty space (a margin) before and after your headings.
Note that the HTML <head> element has nothing to do with HTML headings. the <head> element defines the document’s head element, whereas <h1toh6> defines HTML headings. The <head> element contains meta data, data about the HTML document (not displayed). It is placed between the <html> tag and the <body> tag.

You may also like...