In the previous module, we learned how to create forms.
In this module, we will learn about Semantic HTML. Semantic HTML helps us organize our webpages using meaningful tags. These tags tell browsers and people what each part of a webpage does.
Semantic means "having meaning."
Instead of using tags that say nothing about their purpose, Semantic HTML uses tags that clearly explain what they contain.
Imagine a toy box with labels. One box says "Cars," another says "Books," and another says "Games." The labels help you know what is inside each box.
Semantic HTML works the same way.
The <header> tag contains the top section of a webpage.
<header>
<h1>My School Website</h1>
</header>
The header is like the title page of a book. It tells visitors what the website is about.
The <nav> tag contains links that help visitors move around a website.
<nav>
<a href="#">Home</a>
<a href="#">About</a>
<a href="#">Contact</a>
</nav>
Think of navigation as road signs that help people find their way.
The <main> tag contains the most important information on a webpage.
<main>
<p>Welcome to my website.</p>
</main>
If a webpage were a school, the main section would be the classroom where most learning happens.
The <section> tag divides content into different parts.
<section>
<h2>My Hobbies</h2>
<p>I enjoy football.</p>
</section>
Each section focuses on a specific topic.
The <article> tag contains a complete piece of content, such as a story, news article, or blog post.
<article>
<h2>My Trip to the Zoo</h2>
<p>I saw lions and elephants.</p>
</article>
An article is like a chapter in a book. It can stand on its own and tell a complete story.
The <footer> tag contains information shown at the bottom of a webpage.
<footer>
© 2026 My Website
</footer>
The footer is like the last page of a book, where you often find extra information.
Imagine your room is organized with labeled shelves. You can find things faster because everything has a place. Semantic HTML keeps webpages organized the same way.
<!DOCTYPE html>
<html>
<head>
<title>My Website</title>
</head>
<body>
<header>
<h1>My Website</h1>
</header>
<nav>
<a href="#">Home</a>
<a href="#">About</a>
</nav>
<main>
<section>
<h2>About Me</h2>
<p>I love coding.</p>
</section>
<article>
<h2>My First HTML Project</h2>
<p>I created a webpage about my hobbies.</p>
</article>
</main>
<footer>
© 2026 My Website
</footer>
</body>
</html>
Fill in the blanks:
Create a webpage with:
Fix the missing tags below:
<_____>
<h1>My School Website</h1>
</_____>
<_____>
<a href="#">Home</a>
</_____>
<_____>
Welcome to my school website.
</_____>
Use:
Create a webpage called myprofile.html.
Include:
Create a "My School Website" page using: