New Tool Radar

AI Design Workflows

How to Write Alt Text for AI-Generated Images Before You Publish Them

Write alt text for each AI-generated image by deciding what the image does on the page — informative, decorative, or functional — and describing that purpose in one short sentence.

Schematic diagram: three steps to write alt text — decide the job, write one sentence, give decoration an empty alt — with a practice result of 3 images needing words and 2 getting an empty alt attribute.

An AI-generated image on a page is silent to anyone using a screen reader unless somebody writes down what it is for. Alt text is that writing: a short text alternative that says what the image carries. The hard part is not the writing. It is deciding what the image does on the page, because the same picture needs different alt text in different places — or none at all.

Decide the job before you write the words

The W3C Images Tutorial says images must have text alternatives that describe the information or function represented by them, and it sorts images by purpose: informative images, decorative images, functional images, images of text, complex images, groups of images, and image maps. For an informative image, the text alternative should be at least a short description conveying the essential information presented by the image. For a decorative image, provide a null text alternative (alt="") when the only purpose of an image is to add visual decoration to the page. For a functional image, such as a link or a button, the text alternative should describe the functionality rather than the visual image.

The same tutorial says images “can create major barriers when they are not accessible.” That is the problem this check fixes: an AI image that was never given alt text is a gap in the page, and an AI image given the wrong kind of alt text — a long description of a decoration, or a picture description on a button — is noise.

Write one sentence per image, then check it out loud

For each AI-generated image on the page, ask what it does. If it carries information the text does not, write one short sentence with that information. If it is only decoration, write an empty alt attribute, alt="", so assistive technology skips it — do not leave the attribute out, or some screen readers will read the file name instead. If the image is a button or a link, write what it does, not what it shows. If the image contains words, the alt text should contain the same words. Read each one out loud: if it sounds like a caption for a picture nobody can see, it is probably right; if it sounds like a description of pixels, rewrite it.

Practice alt-text check: fictional Maple Corner page

The five images below are fictional practice material. They were not published on a real page for this guide; they are a practice set so you can see how the check works.

Image What it does on the page Alt text
Hero photo of the cafe counter Informative — shows the counter and the menu board “A small cafe counter with maple leaves and a chalkboard menu.”
Leaf-pattern border Decorative — adds decoration only alt=”” — skipped by screen readers
Order button image Functional — opens the order page “Order the autumn menu”
Photo of the printed menu board Image of text — the words are the content “Maple Corner — Autumn menu, pumpkin spice latte.”
Leaf illustration beside the “About us” text Decorative — the text already says the same thing alt=”” — the text beside it carries the meaning

Three of the five images need words, and two need an empty alt attribute. The two empty ones are not mistakes: a decorative image with a long description would add audible clutter for no information. The test is purpose, not appearance — the leaf border and the leaf illustration look similar, but one sits alone as decoration and the other sits beside text that already says what it means.

What to do when you cannot decide

If you cannot tell whether an image is informative or decorative, look at the text around it. If removing the image would remove information a reader needs, it is informative and needs words. If removing it would change nothing except the look, it is decorative and gets an empty alt attribute. If the image is a chart or a diagram with data, a short alt text is not enough: give a short alt text and a full-text equivalent of the data nearby, as the W3C tutorial says for complex images.

Expected result. We checked the W3C Images Tutorial. We did not run any design tool on the Maple Corner images.

Limits

This check writes alt text; it does not check whether the image itself is accurate, appropriate, or the right image for the page. It also does not cover video, audio, or interactive content. Alt text is a judgment the author makes about purpose, and two reasonable people can disagree about a borderline image — what matters is that the decision is made deliberately for every image, not left blank by default. Maple Corner is fictional, and the five images above are practice material.

Sources

  • Images Tutorial — Web Accessibility Initiative (WAI), W3C — “Images must have text alternatives that describe the information or function represented by them.” For informative images, “the text alternative should be at least a short description conveying the essential information presented by the image”; for decorative images, “Provide a null text alternative (alt=””) when the only purpose of an image is to add visual decoration to the page”; for functional images, “the text alternative of an image used as a link or as a button should describe the functionality of the link or button rather than the visual image.” Also: images “can create major barriers when they are not accessible.”
See all