Course contentsShow
← Web Development
Lesson 1140 of 2,98220. Screen Readers and Assistive TechnologyFree lesson

Decorative Images and Empty Alt

Using alt="" for purely decorative images to prevent screen readers from announcing unnecessary content.

Decorative Images and Empty Alt

What you'll learn: How to mark purely decorative images with empty alt attributes so screen readers skip them entirely.


Not every image carries information. Some images exist solely for visual appeal — decorative borders, spacers, background patterns, or design flourishes. When a screen reader encounters these images, announcing them clutters the experience with irrelevant noise.

Think of it like this: if someone described a room to you over the phone, you'd want to hear about the furniture and exits, not every paint swirl on the wallpaper.

How to Mark Decorative Images

Use an empty alt attribute (not a missing one):

<img src="decorative-flourish.png" alt="">

Notice alt="" — the attribute exists but contains no text. This tells assistive technology: "This image conveys no information. Skip it."

What Makes an Image Decorative?

Ask yourself: If I removed this image, would any information be lost?

  • Decorative borders or dividers → alt=""
  • Pure aesthetic backgrounds → alt=""
  • Icon duplicating adjacent text → alt=""
  • Design elements without meaning → alt=""

Common Mistake

Do not omit the alt attribute entirely:

<!-- Wrong - missing alt triggers warnings -->
<img src="border.png">

Screen readers may announce the filename instead, creating confusion.


Key Takeaway: Use alt="" (empty, not missing) for decorative images so screen readers ignore them and users hear only meaningful content.