Walnut desk lamp
$49.00
Perceivable · 1.1 Text Alternatives
Images, icons and other non-text content need a text alternative serving the same purpose. Controls need a name stating their purpose; media, tests and sensory content need at least a descriptive label; CAPTCHAs need a label plus a version in another sense; decoration must be hidden from assistive technology.
Live demo
The same task, done two ways: switch between the version that passes and the one that fails, or put them side by side. Everything in the box is live, so try it with a keyboard, a pointer or a screen reader.
Read what the screen reader says in each version. Listen for the lamp photo, the star rating, the search button and the dashed line.
$49.00
$49.00
The tools follow the version you last used.
What happened
Why it passes
Each image says what it shows: the lamp, a rating of 4 out of 5 and a Search button. The decorative line is skipped, so nothing gets in the way.
Why it fails
A blind shopper hears a file name instead of a lamp, gets no rating, meets a button with no name, and hears about a line that means nothing.
Examples
Five examples, each one running: the usual ways this criterion fails, and code that passes. Listen to them, measure them, or copy the code.
Fails
Live preview
<h3>Walnut desk lamp</h3><img src="/img/IMG_0042.jpg" alt="IMG_0042.jpg">
A screen reader reads out the file name, which tells a blind shopper nothing about the lamp. This is failure F30: a text alternative that is not an alternative.
Passes
Live preview
<h3>Walnut desk lamp</h3><img src="/img/lamp-walnut.jpg" alt="Desk lamp with a walnut base and a brass shade"><img src="/img/flourish.svg" alt="">
The photo's alt says what a sighted shopper sees. The flourish is decoration, so alt="" tells screen readers to skip it; alt="flourish" would only add noise (failure F39).
+ aria-label="Search" + aria-hidden="true"
Fails
Live preview
<button type="submit"> <svg viewBox="0 0 24 24" width="20" height="20"> <circle cx="10" cy="10" r="6" fill="none" stroke="currentColor" stroke-width="2"/> <path d="M15 15l5 5" stroke="currentColor" stroke-width="2"/> </svg></button>
The button holds only a drawing, so it has no accessible name. A screen reader says just "button", and the user cannot tell that it searches.
Passes
Live preview
<button type="submit" aria-label="Search"> <svg viewBox="0 0 24 24" width="20" height="20" aria-hidden="true"> <circle cx="10" cy="10" r="6" fill="none" stroke="currentColor" stroke-width="2"/> <path d="M15 15l5 5" stroke="currentColor" stroke-width="2"/> </svg></button>
aria-label gives the button the name "Search", and aria-hidden keeps the drawing itself out of the accessibility tree.
Passes
Live preview
<figure> <img src="/img/sales-q3.png" alt="Bar chart. Online sales rose each month: $2.1m in July, $2.8m in August and $3.4m in September."> <figcaption>Online sales, third quarter</figcaption></figure>
The alt gives the figures and the trend, not only the title. An alt of "Sales chart" would name the image but hide what it shows.
Why it matters
Blind and low-vision people get the information through a screen reader or braille display, and text alternatives can also be enlarged or read aloud for people who have trouble interpreting images.
W3C: Understanding 1.1.1Level A
Level A is the minimum: failing it can shut some people out completely.
Where it is required
Required where the law names WCAG 2.0 or later at this level: the United States, Canada, the European Union, the United Kingdom, France, Germany, Italy, Spain, the Netherlands, Ireland, Norway, Switzerland, India, Japan, Australia, New Zealand and Israel.
How to test
A few concrete steps. Automated tools find some failures; most need a person.
Common failures