Skip to content

SEO

Alt text: an accessibility and SEO method by image type

Choose alternative text according to an image’s function, with a decision tree and examples for informative, decorative and functional images.

By
Naïm Ghezali
Publication date
Reading time
5 min read
Abstract editorial composition about acquisition and visibility for the article “Alt text: an accessibility and SEO method by image type”.

Short answer

Write alternative text according to the image’s function in context, not a keyword list. An informative image gets a brief description of the useful information; an image button or logo used alone in a link describes the action or destination; a complex chart also requires an explanation or data on the page. A purely decorative image should retain the attribute with an empty value: alt="". Omitting the attribute is not equivalent. Google uses alt text with nearby content and its visual systems to understand the image, but no alternative text guarantees a ranking. The priority remains an experience that makes sense when the image is not perceived.

ALT: an attribute whose value depends on context

People often say “ALT tag,” but technically alt is an attribute of the img element. The MDN reference explains that its property reflects that attribute and can provide replacement text when the image does not display.

Its primary purpose is not to place a keyword. It is to preserve information or function when the image cannot be perceived. The same file can therefore receive different text depending on its use, or an empty ALT when it becomes decorative.

1. The five-question decision tree

W3C WAI provides a decision tree based on function and context. Adapt it as follows:

  1. Does the image add information absent from the text? Briefly describe that information.
  2. Does it trigger an action or link? Describe the action or destination, not only its appearance.
  3. Does it contain text that appears nowhere else? Reproduce the useful text, unless real text would be a better solution.
  4. Is it complex? Summarize the essential idea in the ALT and provide details in the content, a table or an accessible long description.
  5. Is it decorative or redundant? Use alt="".

If the function remains unclear, the problem may lie in the content itself. Ask what a user needs to understand or do without seeing the image.

2. Informative image: describe the useful information

A product photo should distinguish what this view adds. For example, if the page presents several angles of a bag:

  • Too vague: alt="bag".
  • Needless stuffing: alt="cheap leather bag luxury black women bag".
  • Contextual: alt="Front view of black leather Alba bag with gold clasp".

If the name, color and view already appear directly alongside it and the image adds nothing, repeating everything may become noise. The judgment depends on the page.

Seven Gold recommendation. Write the ALT after the caption and neighboring copy. You will see what is missing more easily instead of copying the heading.

3. Decorative image: empty does not mean absent

For a texture, visual divider or atmospheric illustration with no information, use alt="". The WAI tutorial on decorative images explains that an empty value allows assistive technologies to ignore them. Omitting the attribute may cause some screen readers to announce the file name.

Three common cases:

  • the image repeats adjacent text exactly;
  • it enlarges the clickable area without changing the label’s meaning;
  • it adds only atmosphere or shape.

Fact: an empty ALT is a valid semantic decision. Hypothesis to verify: the image adds nothing necessary in this context. If it distinguishes a product, alert or step, it is no longer decorative.

4. Functional image: name the action or destination

When the image alone acts as a button or link, describe what happens:

  • printer icon alone: alt="Print this page";
  • magnifying glass alone in a button: alt="Search" if no accessible name is provided elsewhere;
  • Seven Gold logo alone in a home-page link: alt="Seven Gold home";
  • logo accompanied by the text “Seven Gold — Home” in the same link: the image can often use alt="" to prevent repetition.

Describing a “black magnifying-glass icon” does not communicate the action. Conversely, do not add ALT text when the component already has a reliable accessible name and doing so creates duplication: test the result in the accessibility tree.

5. Charts, maps and screenshots: move details out of the ALT

A chart generally cannot be made accessible with one endless sentence. Put the subject and main conclusion in the ALT, then provide the data or analysis nearby.

Hypothetical example:

  • ALT: alt="Monthly change in qualified inquiries, rising until June then stabilizing".
  • Nearby content: a table with the monthly values, period, definition of “qualified inquiry” and a note on limitations.

For a screenshot, describe the task or problem shown: “Error message after form submission” is often more useful than an inventory of every color and button. If steps must be followed, write them in the page copy.

6. What alternative text does—and does not do—for SEO

In its image best practices, Google explains that it uses ALT with page context and its vision systems to understand the subject. It advises useful, contextual content and discourages keyword stuffing.

Nearby text, the caption, page title, file name and overall relevance also matter. A poorly placed image with optimized ALT does not automatically become a Google Images result.

Fact: ALT provides a signal for understanding and supports accessibility. Recommendation: use terms people recognize when they genuinely describe the image. Hypothesis: a more precise description may improve discoverability; no ranking or traffic should be promised without measurement.

7. Establish an editorial rule at scale

A spreadsheet completed after the fact often produces generic ALT text. Integrate the decision into the media workflow instead:

  1. state the function: informative, functional, complex, text or decorative;
  2. provide the usage context and page;
  3. write or validate the ALT during implementation;
  4. check duplicates, announced file names and image links without a name;
  5. test with a keyboard, the accessibility tree and, on a sample, a screen reader;
  6. review after a component or context changes.

For large libraries, automation can propose a draft or flag missing attributes. It must not decide alone whether an image is decorative, nor invent a product, person or outcome that is not visible.

8. Images of text, languages and reuse

When an image contains essential text absent from the HTML, the alternative text should convey the necessary information. Where possible, however, prefer real text: it resizes, translates, copies and customizes more easily. A hook already present as an adjacent heading does not need to be repeated word for word in the ALT of a decorative visual.

When translating, do not automatically copy the French ALT. Localize the wording and reassess the context: the image may be informative in one version and redundant in another. If the visual itself contains text, plan a localized asset or an equivalent accessible alternative.

Pre-publication checklist

  • Is the ALT attribute present on every img element?
  • Does the value reflect the image’s function on this specific page?
  • Does a decorative image use alt="" rather than a generic word?
  • Does a functional image communicate the action or destination?
  • Are details from a complex image also available in an accessible format?
  • Does the text avoid keyword stuffing, repetition and information that is not visible?

You have many images and inconsistent ALT text? Seven Gold can include accessibility and image optimization in your SEO audit. Audit image SEO and accessibility.

What this changes in a growth system

An isolated lever rarely produces lasting results. Value comes from consistency between strategy, acquisition, conversion and measurement.

Frequently asked questions

Should a decorative image have empty ALT text?
Yes. If it is genuinely decorative or redundant in that context, retain the attribute as alt="". This allows assistive technologies to ignore it. Omitting the attribute entirely may cause some screen readers to announce the file name.
Should every ALT contain an SEO keyword?
No. The text should first convey the useful information or function of the image. Google discourages keyword stuffing. A search term can appear naturally when it genuinely describes the image and context, without forced repetition.
What is the ideal length for alternative text?
There is no universal length. Be as brief as possible and as precise as necessary. For a complex chart, keep the ALT focused on the central idea and provide details or data in the nearby content.

Turn reading into a decision.

A diagnostic maps your marketing, identifies friction points and sets clear priorities.

Request a diagnostic