HTML5 <h1> to <h6> Tags

Example

The six different HTML headings:

<h1>This is header 1</h1>
<h2>This is header 2</h2>
<h3>This is header 3</h3>
<h4>This is header 4</h4>
<h5>This is header 5</h5>
<h6>This is header 6</h6>

Try it yourself »

Definition and Usage

The <h1> to <h6> tags define headers.

<h1> defines the largest header. <h6> defines the smallest header.


Differences Between HTML 4.01 and HTML5

The "align" attribute was deprecated in HTML 4.01, and is not supported in HTML5. Use CSS to align elements.


Standard Attributes

The <h1> to <h6> tags also supports the Standard Attributes in HTML5.


Event Attributes

The <h1> to <h6> tags also supports the Event Attributes in HTML5.