Web & SEO

What is alt text?

Alt text is a written description attached to an image, read aloud by screen readers and shown when the image fails to load.

New to Bolt? Sign up free.

Technical definition

Alt text is set through the alt attribute on an image element. Screen readers announce it in place of the image, browsers display it when the file cannot load, and search engines use it as a signal for what the image depicts.

Images that are decorative should carry an empty alt attribute rather than a description, which tells a screen reader to skip them. Images carrying information need alt text that conveys that information. Images inside links need alt text describing the link's destination, not the picture.

In plain terms

Describe what the picture shows, in a sentence, as if you were telling someone over the phone.

If the picture is just decoration and carries no information, leave the description empty so screen readers pass over it instead of reading out image dot jay peg.

Why it matters

Alt text is the accessibility fix with the widest reach and the lowest cost, which is why it is worth getting right rather than automating badly. A photo on a bakery site described as image1234 tells a blind customer nothing. Described as a tray of sourdough loaves cooling on a rack, it tells them what is on the page.

The common mistakes are stuffing keywords, which helps nobody and reads as spam, and describing every decorative element, which forces screen reader users to sit through descriptions of background textures. Ask what the image is doing on the page. If the answer is nothing, empty alt. If the answer is something, say what that something is.