The <section>
tag defines a standalone section of content that is related and grouped together under a common theme. It is a semantic HTML5 element and is often used to break a page into meaningful parts.
Use <section>
to divide your page into blocks like "About Us", "Services", or "Testimonials", each with its own heading. This improves structure, accessibility, and SEO.
<section> <h2>Our Services</h2> <p>We offer web development, app development, and digital marketing.</p> </section>
<!DOCTYPE html> <html> <head> <title>Section Example</title> </head> <body> <header> <h1>My Website</h1> </header> <section> <h2>About Us</h2> <p>We are a tech company focused on modern web solutions.</p> </section> <section> <h2>Our Team</h2> <p>Our team consists of experienced developers and designers.</p> </section> </body> </html>
<section>
<section>
as a generic container; use <div>
for thatThe <section>
tag helps organize your content into meaningful sections, making your HTML more semantic and easy to navigate.
Help others discover Technorank Learning by sharing your honest experience.
Your support inspires us to keep building!