Skip to content
Technical

Alt text (alternative text)

Also known as: alt attribute · alt tag · alternative text · image alt

A screen reader reads the alt text aloud, and a browser shows it when the image fails to load. Google uses alt text together with computer vision and the content of the page to understand what an image is about. If the image is a link, Google uses the alt text as the link's anchor text.

Why it matters

Without an alt attribute, some screen readers read out the file name instead. Good alt text makes the page accessible and gives search engines context. Stuffing it with keywords backfires: Google calls that a poor user experience that may cause your site to be seen as spam.

What to do

  • Briefly describe what the image shows and what matters for the page: "Wholemeal sourdough loaf, sliced on a wooden board" rather than "bread".
  • Give a decorative image an empty alt (alt="") so screen readers skip it. Do not leave the attribute out altogether.
  • For an image inside a link or button, describe where it leads or what it does, for example "Home page" for a linked logo.
  • If the image contains text, include the same text. For a chart, also explain the key information in the text.
  • The title attribute is no substitute for alt, and Google does not index images that only appear as a CSS background.

Sources

  1. Google Search Central: Image SEO best practices
  2. W3C WAI: An alt Decision Tree
  3. MDN: <img>: The Image Embed element
  4. Google Search Central: Link best practices for Google

Related terms

← All terms

How does your site perform?

The free scan checks your technical setup and measures whether ChatGPT, Gemini, Claude and Perplexity mention you.

Start free scan