An ALT attribute is the HTML attribute used in HTML / XHTML documents to provide an alternative text that should be rendered in the event that the element attached does not render – most commonly applied to images.
ALT attributes are a class of HTML tags used to provide text based descriptions in the event that the attached HTML element does not load. The purpose of an ALT TAG is to provide descriptive information of the element that failed to render. The purpose of this is to keep the end user aware of what they are looking at.
Traditionally, many marketers/SEO believed there to be SEO value in assigning keywords to ALT Tags to increase keyword density within a page – this of course is not the case.
ALT attributes/tags are actually associated with accessibility / usability and therefore relate to user experience.
What is an ALT Tag
An ALT Tag is a piece of HTML that is attached to a HTML element such as an IMAGE that provides a text based description alternative should the attached HTML element fail to load/render.
What is an ALT Tags main purpose?
An ALT Tags main purpose is to provide a description for end users where images/resources may fail to load or for devices which may be unable to render specific HTML elements. This purpose is tied in with user experience, adding a text description lets the end user know what the image would have been had it rendered.
Where do ALT Tags Go? What do they look like?
ALT Tags can be attached to almost any HTML element involved in the visible makeup of a webpage. Typically an ALT tag will go after the resource i.e.
<img src=”http://www.assertive-media.co.uk/logo.png” alt=”Assertive Logo”>
The tag itself is alt=”” and within the “” is the resource descriptor.
ALT attributes can be assigned to as many elements within the page as required, typically all images should have an ALT attribute where possible.
What other Alt Text Uses are there?
Adding alternative text to photos and images is a key principle of website accessibility and is key in providing all users with an opportunity to understand a webpages elements. Users with disabilities or visual impairment may use a screen reading device which can annotate ALT Tags so that the images can be explained.
ALT Tags can also help search engines better understand what the image is about. This may change in the future as Google uses AI to recognise what images actually are as opposed to being spoonfed descriptions.
How should ALT Tags be used?
ALT tags should be used exactly the way they were intended. Allocated alt descriptions should describe what the element/images is about, briefly and accurately.
GOOD ALT ATTRIBUTE USE >
<img src=”yellow-ford-car.png” alt=”a picture of a Yellow Ford Car Outside”>
BAD / POOR ATTRIBUTE USE >
<img src=”yellow-ford-car.png” alt=””>
<img src=”yellow-ford-car.png” alt=”Car”>
SPAMMY ATTRIBUTE USE >
<img src=”yellow-ford-car.png” alt=”Yellow Ford Car, Ford Car in Yellow, Yellow Ford Mondeo Car”>
Try and imagine if you were looking at the element/image and it didn’t load, would your description of that image be a good one?
- Make them accurate
- Keep them short and too the point – don’t go writing sentences in an ALT TAG
- Do not stuff in keywords
- Do not use duplicate ALT TAGS unless the same image is being used more than once
How do I write an Alt Tag?
ALT Tags should be written with the end user in mind, keeping things factual, to the point and descriptive enough that the end user will understand.
- Write using clear and concise English
- Keep your word limit in mind, ideally 10 or less words should suffice
- Do not use ALT Tags as an opportunity to jam in keywords
Are ALT Tags Important?
ALT Tags are key to accessible web design / website accessibility. ALT Tags are of importance, but, not using them is unlikely to have any detrimental impact on organic rankings. Best practice dictates the use of ALT Tags, but, Google will often place little emphasis on ALT tags due to their frequent overuse/misuse.
How do I write an ALT Tag for SEO?
The answer is, you don’t. ALT attributes impact user experience/accessibility (which are major SEO factors), so think about making your ALT attributes reliable and accurate – this is going to be more beneficial then integrating keywords.