What is alt text?

Alt text is the words that stand in for an image when the image can't be seen. It lives in the alt attribute of an <img> element, and people call it alt text, an alt tag, an alt attribute or an alt description. Same thing.

<img src="teapot.webp" alt="Sage-green ceramic teapot with a bamboo handle">

Hear the difference

A screen reader turns the page into speech. Pick an alt value below and hear what someone using one would get from the same linked product photo.

Screen reader says

“link, image, Sage-green ceramic teapot, view product”

<a href="/teapot"><img src="sage-green-teapot.webp" alt="Sage-green ceramic teapot, view product"></a>

Short, specific, and says what the link does. This is what a sighted visitor gets from a glance.

Who alt text is for

  • Screen reader users. Blind and low-vision visitors hear or feel (on a braille display) the alt text in place of the image.
  • People whose images don't load: slow mobile data, blocked hosts, email clients that hide images by default. The browser shows the alt text instead.
  • Voice-control users, who say "click Sage-green teapot" to follow an image link.
  • Search engines. Google describes alt text as the most important attribute for giving it information about an image. See alt text for SEO.

What the rules say

WCAG 2.2, the W3C standard most accessibility laws point to, starts with success criterion 1.1.1 Non-text Content (Level A): all non-text content presented to the user has a text alternative that serves the equivalent purpose. Decorative images must be implemented so assistive technology can ignore them, which in HTML means alt="".

Source: W3C, Understanding Success Criterion 1.1.1.

Alt text vs. caption vs. title

Who sees itJob
altScreen reader users, broken-image fallback, search enginesReplace the image
<figcaption>EveryoneAdd context the image doesn't show
titleMouse users on hover onlyTooltip; not a substitute for alt

Writing your first one

Ask: if I replaced this image with a sentence, what sentence would keep the page working? That sentence is the alt text. If the page works just as well with the image deleted, it is decorative and gets alt="". The best practices guide turns that into a step-by-step decision, and the alt text generator writes a first draft for you.

Questions people ask

What is alt text?

Alt text (alternative text) is a short written replacement for an image, stored in the alt attribute of an HTML <img> element. Screen readers read it aloud, browsers show it when the image fails to load, and search engines use it to understand the image.

Is alt text the same as an alt tag?

Yes, in everyday use. "Alt tag" is a common but technically wrong name: alt is an attribute of the <img> tag, not a tag of its own. "Alt text", "alt attribute", "alt description" and "alt tag" all refer to the same thing.

Is alt text required?

For accessibility, yes: WCAG 2.2 success criterion 1.1.1 requires a text alternative for non-text content, and the HTML standard requires the alt attribute on images in almost all cases. Laws such as the ADA (US), the European Accessibility Act and the UK Equality Act are commonly enforced against WCAG.

Who uses alt text?

Blind and low-vision people using screen readers or braille displays, people who turn images off to save data, anyone on a slow connection when an image fails, voice-control users who click by name, and search engines and AI crawlers indexing the page.

What is the difference between alt text and a title attribute?

Alt replaces the image. The title attribute shows a hover tooltip, is not reliably read by screen readers, and never appears on touch screens. Do not use title instead of alt, and do not repeat alt in title.