Customization in HTML Heading Tags
The default size of HTML headings can be changed, using the style attribute.
Example: In this example explains the HTML heading tags by specifying the size of the font.
<!DOCTYPE html>
<html>
<body>
<h1>H1 Heading</h1>
<!-- With the help of Style attribute you can customize
the size of the heading, As done below-->
<h1 style="font-size: 50px">H1 with new size.</h1>
<!-- Here font-size is the property by which we can
modify the heading. Here we kept it 50px i.e. 50 pixels -->
</body>
</html>
Output:
HTML Headings
HTML headings, from <h1> to <h6>, indicate content hierarchy and importance. Search engines use them for indexing. Users navigate by headings. Employ <h1> for main titles, <h2> for subsections, and progressively lower levels for less important content to maintain structure and readability.
HTML provides six levels of heading elements, ranging from <h1>
(highest level) to <h6>
(lowest level).
Contact Us