The <article> Element
What you'll learn: How to use the <article> element to mark content that stands on its own and could be distributed independently.
What Is an <article>?
The <article> element is a semantic HTML container for self-contained content that makes sense by itself, even if you pulled it out of your website and placed it somewhere else. Think of it as content that could be independently distributed or reused—like a blog post, a news article, a forum post, or a product card.
The "Newspaper Test"
Here's a helpful analogy: if you imagine a newspaper, each individual story is an article. You could cut out that story, hand it to someone, and they'd understand it completely without needing the rest of the newspaper. That's exactly what <article> represents on a webpage.
When to Use <article>
Use <article> for content that:
- Has its own heading and makes complete sense alone
- Could be syndicated (shared on other sites)
- Could be posted in an RSS feed
- Is independently distributable
Basic Structure
<article>
<h2>My First Blog Post</h2>
<p>Posted on January 15, 2025</p>
<p>This is the content of my blog post. It's self-contained and complete on its own.</p>
</article>
You can have multiple <article> elements on one page—for example, a blog homepage listing five recent posts would contain five separate <article> elements.
Key Takeaway: Use <article> to wrap self-contained, independently meaningful content that could stand alone or be republished elsewhere—it tells browsers and assistive technologies "this is a complete unit of content."