Home >>HTML Tutorial >HTML Headings

HTML Headings

HTML Headings

HTML Headings tag is used to define headings at your web page.

There are 6 types of HTML Headings that you can use at web page

<h1> to <h6>

<h1> Tag defines important headings and <h6> defines  the least important heading.

For Example

<h1> Heading 1 </h1>
<h2> Heading 2 </h2>
<h3> Heading 3 </h3>
<h4> Heading 4 </h4>
<h5> Heading 5 </h5>
<h6> Heading 6 </h6>
Try it Yourself

Output

Heading 1

Heading 2

Heading 3

Heading 4

Heading 5
Heading 6

In the above example we shows six different level of heading <h1> to <h6>

HTML Heading tag automatically break the lines if you want to put extra space then use either <br/> or <hr/> Tag

For Example
<h1> Heading 1 </h1><br/>
<h2> Heading 2 </h2><hr/>
<h3> Heading 3 </h3>

Try it Yourself

In the above example

i) In the first line we declare heading tag <h1> with <br/> tag, br tag is used to break the line.

ii)In the second statement, we use <hr> tag which displays the line across the heading 2.

iii)In third statement <h3> simply used to display sub-heading.

Total Downloads : 149

Login / Register To Download

No Sidebar ads