How to write alt text for your website's images
What alt text is, who relies on it, and how to write short, useful descriptions for the photos, logos and icons on a small-business website, with examples.
By The SayMySite team · Published · 5 min read
Alt text is a short written description attached to an image on a web page. Most visitors never see it. But for people who are blind or have low vision and use a screen reader, it's the only way to know what an image shows. It's also shown if an image fails to load, and it helps search engines understand your pictures.
Writing it well takes a few seconds per image once you know the knack. This guide explains how, with examples from real kinds of small business.
Who relies on it
A screen reader is software that reads a web page out loud, or sends it to a braille display. When it reaches an image, it reads the alt text. If there's none, it may read the file name instead, something like "IMG underscore 4 0 7 1 dot jpeg", or skip the image entirely.
So alt text is how a blind customer learns that your photo shows a freshly tiled bathroom, or that the image at the top of the page is your logo. Our broader guide to making your website accessible covers the other basics.
The one question to ask
For each image, ask: what would I say about this picture if I were describing the page to someone over the phone?
That's your alt text. Usually it's one short sentence, and it focuses on why the image is on the page, not every detail in it.
Examples
A plumber's photo of a finished job
- Weak: "image", "photo", "plumbing"
- Better: "New white sink and chrome faucet fitted in a small kitchen"
A bakery's product photo
- Weak: "cake1.jpg"
- Better: "Three-tier lemon wedding cake decorated with fresh flowers"
A hair salon's team photo
- Weak: "team"
- Better: "Salon owner Maria and stylists Jen and Ade standing at the front desk"
A landscaper's before-and-after
- Better, as two images: "Overgrown backyard before the work" and "The same backyard with a new lawn and stone path"
Notice what's missing from the better versions: "image of" and "picture of". Screen readers already announce that it's an image, so starting with "image of" just repeats it.
Rules of thumb
- Keep it short. A sentence is plenty; a common rule of thumb is under about 125 characters. Long detail belongs in the page text, where everyone can read it.
- Describe what matters on this page. The same photo of a dog might be "Golden retriever after a full groom and trim" on a grooming site and "Our office dog, Biscuit, asleep under the reception desk" on an About page.
- Don't stuff keywords. "Best plumber Springfield cheap plumber emergency plumber" is unhelpful for people and search engines can see through it. A natural description that mentions what's shown is enough.
- Include text that's in the image. If a picture contains words, like a sign, a poster or a price list, the alt text should include them. Better still, put important text on the page as real text instead of inside an image.
- End with a period if you like. It makes some screen readers pause naturally. It's optional.
Special cases
Your logo
If the logo links to your homepage, which is common in the header, the alt text should say where it goes or name the business: "Harbor Plumbing home". If it's just there for decoration next to your business name in text, it can be treated as decorative.
Decorative images
Some images add nothing to the meaning: background textures, dividing lines, a stock photo of a coffee cup that's purely mood. These should have empty alt text, which tells screen readers to skip them. In most website builders there's a checkbox like "decorative image" or you simply leave the alt field empty on purpose. Empty is different from missing: missing alt text makes some screen readers read the file name.
Icons and buttons
If an image is a button or link, like a phone icon that dials your number or a magnifying glass that opens search, the alt text should say what it does: "Call us" or "Search", not "phone icon".
Charts, maps and infographics
Give a short alt text, like "Map of our service area", then put the important information in the page text: "We cover Springfield, Shelbyville and everywhere within 20 miles." That helps everyone, including people who find maps hard to read.
Photos of documents or menus
A photo of a printed menu or price list is very hard for screen reader users and often hard to read on a phone. Type the menu or prices onto the page as real text, and use the photo as decoration if you like.
Where to add it
Almost every website builder and content system has an "alt text", "alternative text" or "image description" field when you upload or edit an image. Social media platforms have one too, often under advanced or accessibility settings. It's worth adding there as well.
If you're not sure whether your images have alt text, free browser extensions and online accessibility checkers can list the images on a page that are missing it.
A five-minute fix for your site
- Open each main page of your site: homepage, services, about, contact.
- For each image, check the alt text field.
- Rewrite anything that's empty, a file name or a string of keywords.
- Mark purely decorative images as decorative.
- Move any important text out of images and onto the page.
For a small site, this is usually a coffee break's work. Do it once, then write alt text as part of uploading every new photo.
The short version
Describe each meaningful image in one short sentence, the way you'd describe it on the phone, focusing on why it's on the page. Skip "image of". Leave decorative images empty on purpose. Make buttons say what they do. Put important words on the page, not inside pictures. It's a small habit that makes your site usable for customers who'd otherwise be left guessing.
Filed under: Accessibility