HTML Headings

  • The HTML headings are used to define the heading of contents.
  • In HTML are  the <h1> to <h6> tags.
  • The largest tag is <h1> and smallest tag is <h6>.

Note: Browsers automatically add some white space (a margin) before and after a heading.

First Program in HTML
<!DOCTYPE html>
<html>
<head>
<title>Use of heading tag</title>
</head>
<body>

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

</body>
</html>

Output

Use of heading tag
This is a Heading 6
This is a Heading 5

This is a Heading 4

This is a Heading 3

This is a Heading 2

This is a Heading 1

What is HTML
  • HTML is the standard  for Hypertext Markup Language for Web pages.
  • The HTML elements tell the browser ...
    Click Here
Previous topic next topic What is an Element in HTML
  • An Hypertext Markup Language(HTML) element ...
    Click Here
Previous topic next topic HTML Headings
  • The HTML headings are used to define the heading ...
    Click Here
Previous topic next topic HTML Formatting Elements
  • The <b>  element is use for bold text, without ...
    Click Here
Previous topic next topic HTML Comments
  • The HTML Comment are describe the extra feature about ...
    Click Here
Previous topic next topic HTML Attributes
  • Every HTML element can have attributes.
  • The HTML Attribute ...
    Click Here
Previous topic next topic HTML Images
  • The <img> tag is empty
Note: The empty ...
Click Here
Previous topic next topic HTML Links
  • HTML links are hyperlinks.
  • HTML link default color is ...
    Click Here
Previous topic next topic HTML Table
  • An HTML table is defined with the <table> tag.
  • ...
    Click Here
Previous topic next topic Table Backgrounds You can set the table background using one of the ...
Click Here
Previous topic next topic Table Header, tbody and Footer
  • Tables are categories into three parts: ...
    Click Here
Previous topic next topic Basic to Advance table design in HTML Example 1 <!DOCTYPE> <html> <body> ...
Click Here
Previous topic next topic HTML div tag
  • The <div>  element is used for style blocks ...
    Click Here
Previous topic next topic HTML Lists
  • The list is the way to present the data ...
    Click Here
Previous topic next topic HTML Form
  • The HTML <form> element is used to collect user ...
    Click Here
English Hindi