The alt attribute is an HTML attribute of the <img> tag that provides a text description of the image. It serves two purposes: accessibility (screen readers read it aloud) and SEO (Google reads it to understand the image content).
HTML syntax
<img src="salomon-xt6.jpg" alt="Salomon XT-6 Women Trail Shoes Black — front view" />
Rules:
- Content image: always a descriptive alt attribute
- Decorative image: empty alt attribute (
alt="") - Never omit the alt attribute entirely (screen reader announces "image" with no context)
Product images
Category images
Lifestyle images
| Alt text | Accessibility | SEO value |
|---|---|---|
| Absent (no attribute) | Poor | None |
| Empty alt="" | OK for decorative | None (intentional) |
| "product" | Poor | Very low |
| "Salomon XT-6 Women Black Trail" | Good | High |
Optimize alt texts at scale
30 min call · no commitment
