AI Prompts for Writing Alt Text That Improves Accessibility and SEO

Close-up of code on a laptop screen, representing the technical work of adding accessible alt text to website images

Alt text is the short written description attached to an image so screen readers can announce it to blind and low-vision visitors, and so search engines can understand what an image shows when they can’t “see” it either. Writing good alt text at scale is tedious by hand, which is exactly the kind of repetitive, rules-based task AI prompts handle well — as long as you give the model the right constraints instead of just asking it to “describe this image.”

What Actually Makes Alt Text “Good,” According to Google and W3C?

The W3C’s Web Content Accessibility Guidelines require that “all non-text content that is presented to the user has a text alternative that serves the equivalent purpose,” which is what Success Criterion 1.1.1 formally establishes as a baseline accessibility requirement.

Google’s own image SEO documentation gives a concrete example of the difference between weak and strong alt text: alt="puppy" is acceptable, but alt="Dalmatian puppy playing fetch" is what they call the better version, because it’s specific and contextual rather than generic. Google also explicitly warns against keyword stuffing in alt text, noting it “results in a negative user experience and may cause your site to be seen as spam.”

The Core Prompt: Writing Alt Text From an Image Description

Since most AI models can only “read” an image if you paste it in directly, this prompt works whether you’re using a vision-capable model with the image attached, or a text-only model where you describe the image yourself:

“Write alt text for this image that will appear on a page about [page topic]. The alt text should: (1) describe what’s actually in the image in plain language, (2) be specific rather than generic (avoid single words like ‘photo’ or ‘image’), (3) stay under 125 characters, (4) include the target keyword ‘[keyword]’ only if it genuinely describes the image, never forced in, and (5) never start with ‘image of’ or ‘picture of’ since screen readers already announce that it’s an image. Do not stuff keywords.”

A Prompt for Auditing Alt Text Across an Entire Page or Post

For existing content, batch-review is faster than fixing images one at a time:

“Here is a list of image filenames and their current alt text from one blog post: [paste list]. Flag any alt text that is missing, empty, generic (like ‘image1’ or ‘photo’), keyword-stuffed, or redundant with the image’s caption. For each flagged image, suggest a replacement under 125 characters.”

When Should an Image Have Empty Alt Text Instead?

Not every image needs a description. Purely decorative images — background textures, dividers, icons that repeat information already in nearby text — should generally use an empty alt="" so screen readers skip over them instead of announcing noise. A useful prompt constraint: ask the model to flag any image in your list that looks purely decorative and suggest empty alt text for those instead of inventing a description.

Don’t Forget File Names and Image Placement

Google’s image SEO guidance also flags file naming as part of the same picture: they recommend descriptive file names like my-new-black-kitten.jpg over generic ones like IMG00023.jpg, and note that Google extracts contextual signals from the text and captions surrounding an image, not just the alt attribute alone. A prompt for this: “Suggest a short, descriptive, hyphenated file name for an image showing [description], following SEO file naming best practices.”

These prompts fit naturally into a broader technical SEO pass alongside schema markup and meta descriptions — all three are small, structured fields that add up to meaningfully better on-page SEO.

Frequently Asked Questions

Is alt text a direct Google ranking factor?

Google doesn’t describe alt text as a standalone ranking signal, but it uses alt text as one of the primary ways it understands what an image depicts for Google Images results, and it’s a required accessibility element under WCAG regardless of any SEO impact. Treat it as necessary for accessibility first and helpful for image search visibility second.

How long should alt text be?

Most accessibility guidance suggests keeping it concise, typically under about 125 characters, since many screen readers truncate longer descriptions. The goal is to describe the image’s purpose and content quickly, not write a full caption inside the alt attribute.

Should every single image on my site have alt text?

Every image that conveys meaning or information needs alt text under WCAG 1.1.1. Purely decorative images are the exception: they should use an empty alt="" attribute rather than a forced, meaningless description, so assistive technology can skip them cleanly.

Sources: W3C WAI – Understanding Success Criterion 1.1.1, Google Search Central – Image SEO best practices.

Leave a Comment

Your email address will not be published. Required fields are marked *

Scroll to Top