What are semantic elements in HTML5? Give examples

Semantic elements are tags whose name tells what the content is. For example <nav> holds navigation links and <footer> is the bottom part of a page. A <div> tells nothing.

  • header, nav, main, footer
  • section, article, aside
  • figure, figcaption, time
<header>Site title</header>
<nav>Menu</nav>
<main>
  <article>Blog post</article>
  <aside>Related links</aside>
</main>
<footer>Copyright</footer>

They help SEO, accessibility and make the code easy to read. See HTML Semantic Elements.


Learn more about the similar topics:
Tutorials
HTML Semantic Elements
HTML Responsive Design
Exercises & Assignments
Write an HTML program to create a navigation menu
Write an HTML program to create a page layout with semantic elements
Interview Questions & Answers
What are semantic elements in HTML5? Give examples
What is the difference between div and section in HTML?
How do you make a web page responsive using HTML and CSS?
What is web accessibility and how does HTML help with it?