Write an HTML program to display all six heading levels
Description: Create a web page that shows the headings from h1 to h6.
Hint:
- Write one tag for each level, with a text like “Heading 1”.
HTML program for heading tags
<!DOCTYPE html>
<html lang="en">
<head>
<title>Headings</title>
</head>
<body>
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<h4>Heading 4</h4>
<h5>Heading 5</h5>
<h6>Heading 6</h6>
</body>
</html>
Output in the browser:
Output in the browser
Heading 1
Heading 2
Heading 3
Heading 4
Heading 5
Heading 6
How it works
h1is the biggest and most important heading, andh6is the smallest.- Use only one
h1on a real page.
Read HTML Headings.
Learn more about the similar topics:
| Tutorials |
|---|
| No Content Found. |
| Exercises & Assignments |
|---|
| No Content Found. |
| Interview Questions & Answers |
|---|
| No Content Found. |