HEADING IN HTML
Headings help in defining the hierarchy and the structure of the web page content.
HTML offers six levels of heading tags, <h1>
through <h6>
; the higher the heading level number, the greater its importance — therefore <h1>
tag defines the most important heading, whereas the <h6>
tag defines the least important heading in the document.
HTML defines six levels of headings. A heading element implies all the font changes, paragraph breaks before and after, and any white space necessary to render the heading. The heading elements are H1, H2, H3, H4, H5, and H6 with H1 being the highest (or most important) level and H6 the least.
By default, browsers display headings in larger and bolder font than normal text. Also, <h1>
headings are displayed in largest font, whereas <h6>
headings are displayed in smallest font.
EXAMPLE :
<h1>Heading level 1</h1>
<h2>Heading level 2</h2>
<h3>Heading level 3</h3> <h4>Heading level 4</h4> <h5>Heading level 5</h5> <h6>Heading level 6</h6>Importance of Headings
- HTML headings provide valuable information by highlighting important topics and the structure of the document, so optimize them carefully to improve user engagement.
- Don't use headings to make your text look BIG or bold. Use them only for highlighting the heading of your document and to show the document 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.
Comments
Post a Comment