HTML Semantic Elements
What are Semantic Elements?
Semantic elements clearly describe their meaning to both browser and developer.
Common Semantic Tags
<header> <nav> <main> <section> <article> <footer>
Example Layout
<header>Header</header> <nav>Menu</nav> <main>Content</main> <footer>Footer</footer>
Why Semantic HTML?
- Better SEO ranking
- Improved accessibility
- Cleaner code structure
- Easier to understand
SEO Tip
Always prefer semantic tags instead of only using divs.