But whatâs so important about alt text? And how can you use it to improve SEO and user experience?
In this guide, youâll learn:
- Why alt text is important
- How to add alt text to images
- Why you shouldnât add alt text to all images
- How to write good alt text
- Examples of good and bad alt text
- How to find and fix issues with alt attributes
Alt text matters for four main reasons.
- Improves accessibility
- Can improve âtopical relevanceâ
- Can help you rank in Google Images
- Serves as anchor text for image links
1. Alt text improves accessibility
Millions of people are visually-impaired, and many use screen readers to consume online content. These work by converting on-screen content, including images, to audio.
Images without alt text cause problems for screen readers because thereâs no way to communicate the content of the image to the user. Usually, they skip over these images, or worse, read out long and unhelpful image filenames.
Google talks about the importance of alt text for users with screen readers in their SEO starter guide.
2. Alt text can improve âtopical relevanceâ
Google looks at the words on a page to understand what itâs about.
For example, if the page mentions poodles, labradors, and retrievers, then Google knows itâs about dog breeds.
How does this relate to images?
Because sometimes, context is âlocked awayâ in images that Google canât read.
While Google can almost certain tell that these are images of dogs without alt text, the specific breed may be less obviousâand thatâs where alt text comes in.
3. Alt text can help you rank in Google Images
Google Images is the worldâs second-largest search engine. Itâs responsible for 20.45% of all online searches, putting it ahead of YouTube, Bing, and other search engines combined.
This means thereâs an opportunity to drive traffic from Google Images.
Just look at the number of clicks weâve had to the Ahrefs Blog from Google Images in the past three months:

Googleâs John Mueller says that alt text is an important part of optimizing for Google Images:
Alt text is extremely helpful for Google Images -- if you want your images to rank there. Even if you use lazy-loading, you know which image will be loaded, so get that information in there as early as possible & test what it renders as.â John (@JohnMu) September 4, 2018
4. Alt text serves as anchor text for image links
Anchor text refers to the clickable words that link one webpage to another. Google uses it to understand more about the web page and what itâs about.
But not all links are text; some are images.
Google states:
If you do decide to use an image as a link, filling out its alt text helps Google understand more about the page youâre linking to. Imagine that youâre writing anchor text for a text link.
Simply add an alt attribute to the <img> tag in the HTMLÂ code.
Image with an alt tag:Â
<img src=âpie.jpgâ alt=âsteak and ale pieâ>
If youâre using a modern CMS, it should be possible to add alt text without having to dig into the HTMLÂ code.
For example, in WordPress, thereâs a field for alt text when adding an image to a page or post:

Things are similar in other CMSâ.
Here are instructions for some of the most popular ones:
No, this is a common misconception.
If the image exists for decorative purposes and doesnât carry important information, then thereâs no need to add alt text.
For example, some websites have icons to separate content:
![]()
These are only there to look pretty, so you shouldnât add alt text. Doing so will only annoy visitors with screen readers, and wonât add any âSEO valueâ to the page.
The same goes for generic or stock images like this:

Having alt text that reads âbath and candleâ isnât useful for visually-impaired readers because itâs information they donât need to know. It would be better to have the screen reader ignore it completely.
But, hereâs an important pointâŠ
If an image doesnât require alt text, best practice is to add an empty alt attribute. This is because some screen readers read out filenames in the absence of an alt attribute, whereas most will skip those with empty ones.
Hereâs what that looks like:
<img src="spacer.gif" alt="">
Learn more in this guide from WebAIM.
Alt text isnât rocket science.
Follow these five best practices, and you should be good.
- Be concise. Lengthy alt text is annoying for those using screen readers. Use as few words as possible. (Use the longdesc attribute if a long description is necessary.)
- Be accurate. Focus on describing the image.
- Avoid keyword stuffing. This is not a place to shoehorn keywords.
- Avoid stating that itâs an image. Thereâs no need to include âImage ofâŠâ or âPicture ofâŠâ in descriptions. Both Google and screen readers can work that out for themselves.
- Avoid redundancy. Donât repeat information that already exists within the context of the image. For example, if you have a photo of Steve Jobs and the text directly below the image reads âSteve Jobs,â thereâs no need to add this description to the alt tag. Google should understand that the caption is effectively the alt text.
You should also remember to add alt text to form buttons. Otherwise, screen readers might pass over them and some visitors wonât be able to interact with your website.
Letâs make sure we understand what works and what doesnât with a few examples.
Bad: <img src=âcheesecake.pngâ alt=âpicture of cheesecakeâ>
Okay: <img src=âcheesecake.pngâ alt=âcheesecakeâ>
Good: <img src=âcheesecake.pngâ alt=âstrawberry cheesecakeâ>
Best: <img src=âcheesecake.pngâ alt=âstrawberry cheesecake with creamâ>
Bad: <img src=âsteve-jobs.pngâ alt=âsteve jobs apple iphone ipad macâ>
Okay: <img src=âsteve-jobs.pngâ alt=âsteve jobsâ>
Good: <img src=âsteve-jobs.pngâ alt=âapple founder, steve jobsâ>
Best: <img src=âsteve-jobs.pngâ alt=âapple founder, steve jobs, holding the iphone 4â>
Bad: <img src=âamp.pngâ alt=âimage4">
Okay: <img src=âamp.pngâ alt=âorange amplifierâ>
Good: <img src=âamp.pngâ alt=âorange amplifier - 30 wattsâ>
Best: <img src=âamp.pngâ alt=âorange AD30HTC - 30 watt amplifierâ>
Note the inclusion of the model number in that final example. This is good practice, especially for images on e-commerce product pages.
Lots of tools are capable of crawling your site and finding missing alt attributes, including Ahrefsâ Site Audit.

But having missing alt text isnât always an issue because not all images require alt text.
For example, take a look at these missing alt attributes:

Itâs clear from the filenames that they donât need alt text. Theyâre decorative, which means weâd want a screen reader to pass right over them.
So, rather than crawling your site and obsessing over every missing alt attribute (most sites have quite a lot of missing ones), a better idea is to audit and improve alt tags for pages that already get traffic.
There are two reasons for this:
- They have visually-impaired readers. 2.4% of US citizens have a vision disability. Thatâs one in roughly every 42 people meaning that on average, if your page gets 10,000 visitors a month, 240 of them canât consume your content properly.
- They could possibly get more traffic. Alt text can help images rank better in Google Images, and that leads to more traffic. Even just a 1% increase to a page with 10,000 monthly visits is an extra 100 visitors.
Hereâs the process:
Step #1. Find your most visited pages from organic search
Check Ahrefsâ Web Analytics:

Or the âTop pagesâ report in Ahrefsâ Site Explorer.

Step #2. Audit your alt attributes
Install the free Alt Text Tester Chrome extension, load up the page with the most traffic, then activate the extension.
You should see the alt text displayed whenever you roll over an image.

If the alt attribute is missing, youâll see a warning.

Check the alt text for a few images on the page. Youâll soon get a feel for whether theyâre optimized well, poorly, or not at all.
For example, it only takes a few seconds of scrolling this post to see that all of the images are well-optimizedâŠ

⊠whereas the same isnât true for this page on The Mirror:

Step #3. Repeat for more pages
Repeat this process for the most visited pages on your website. This should give you a sense of whether your alt text optimization is sound or needs work.
Because most websites get the bulk of their traffic to just a handful of pages, this shouldnât take too long.
For example, just ten posts on the Ahrefs blog account for 51% of monthly organic trafficâŠ

⊠so we can easily audit and optimize alt text for most of our high-traffic pages in minutes.
Final thoughts
Optimizing alt text is important, but itâs not the be-and-end-all of image SEO. You should also optimize filenames, serve responsive images, consider lazy loading, and much more.
Learn more in our list of 12 actionable image SEO tips.










