New Exclusive Deal:Up To 75% OFF a New Website
September 22, 2020
6 min read
An alt tag us an attribute applied to image tags in the HTML code for a web page. They serve as a description of the content of the image and are crucial for search engine optimization and web accessibility.
You might also hear alt tags referred to as “alt attributes” or “alt descriptions”, but these are functionally the same.
When you look in the HTML code of a page, an image alt tag would appear like this:
<img src=”chair.png” alt=”wooden armchair with red cushion” />
Though alt text is usually invisible to regular users (who would only see the image), there are three main purposes that alt tags serve:
It is this purpose we’ll be exploring further in this glossary entry, since it is the most relevant to website building, SEO, and eCommerce.
Software that reads web pages aloud to visually impaired users can describe the image for the user by reading the alt text.
Instead of displaying the image, the web page can display text describing the image, so no meaning is lost to the user.
We mentioned before that alt images texts are key to a successful SEO strategy, and this is true for a combination of reasons:
Now that you have a good handle on what an alt tag for images is and why you should be using them, it’s time to have a look at how they work in practice.
While the format of your alt text for images should be the same regardless of how you choose to build your website (we’ll talk about alt text best practice in a minute), how you enter them into your HTML code will differ depending on how you’re building your site.
If you’re coding a website from scratch, are using an HTML template, or have access to the HTML code for some other reason, it’s simple to add alt tags to your images.
When you have access to the HTML code of the website, you can just add the alt tag by using the format described in the first section above.
If you’re using a CMS, like WordPress, you’ll likely have a couple of options when it comes to adding image alt attributes.
Usually, you can use an image uploader which will have a text box for entering your alt tags. Alternatively, you should also be able to access a page’s HTML code to enter them manually, if you prefer.
If you’re using a website builder, chances are you won’t have direct access to your page’s HTML code. Instead, you’ll need to use whichever mechanism the builder offers for editing alt text.
If you’re using Zyro, for example, you’ll have to select the image, go into the image’s settings, and under the SEO tab, you’ll find the Alt text field.
Since image alt texts have such a big hand in SEO, it’ll come as no surprise that writing them requires an element of finesse.
While you should certainly be thinking about search keywords, these are not the only important aspect of crafting effective alt tags.
Your images are (probably) not the only content on any given web page. Instead, it will exist within the context of other text, titles, and images.
Search engine bots will look at everything together before deciding how to index a page and its images.
To help search engines correctly understand what the overall message of your page is, it’s important that the text in your images’ tags relates to the content elsewhere on our page.
This will ensure that the traffic you get to your website is relevant, and looking for the content you have on offer. This, in turn, will decrease your bounce rate and improve your SEO rankings further.
It’s worth remembering that you’re writing alt text for humans as much as search engine bots. That’s why it’s important to make sure that, while you’re as concise as possible, you also describe the content of images in a comprehensible way.
A clear description will also help the image get found in image searches, where users might be searching for a very specific image.
Be careful though, and don’t overdo it with your descriptions. Search engines like Google prefer indexing shorter alt text. This means that if your alt tags are descriptive but snappy, you’ve got the best chance of getting them properly indexed.
Keywords are the cornerstone of SEO, and image alt texts offer the perfect opportunity to introduce more of your target keywords onto your web pages.
Keywords are the main indicator to search engines what your page is about, and so a high density of related keywords tells a search engine what the purpose and focus of your page is.
While you should focus on ensuring that your image alt texts are descriptive and concise, if it’s appropriate, you should include one or more keywords.
Anyone with even the vaguest knowledge of modern SEO practices will be able to tell you that the number one cardinal sin of writing SEO content is keyword stuffing. Well, the exact same is true for an image SEO alt attribute.
Keyword stuffing is basically what it sounds like; cramming too many keywords into too little space in the hope of tricking search engines into giving the page a better rank.
Turns out search engines are too smart to fall for that, and today it’s just plain bad SEO practice.
Not only will keyword stuffing not achieve any goal (because alt tags are not that important unless your site is very image-driven) but you’ll run the risk of getting penalized by Google.