ALT Text means Alternative Text and refers to the value of the HTML attribute ALT that is often found within IMG elements (images) and within other HTML elements that don’t always load or otherwise aren’t always accessible.
ALT Text exists as a substitute form of information for when images, videos, sound files, Flash objects, Java applets and other rich media formats can’t be seen or interpreted by the user. It’s there in order to help you understand the meaning of the content that you’re unable to see or interpret.
For example, an image element may be coded as <IMG SRC="seo-guide.jpg" ALT="SEO Guide"> – here you can see the image file source is referenced by the SRC attribute, and a textual name or description of the image is provided within the ALT attribute.
In another example, an image may be coded as: <img src="london-bridge.jpg" alt="London Bridge" width="155" height="300">. Again, you can see an image source and some ALT Text, as well as width and height attributes. You may also notice ID and CLASS attributes on some images. Some will also have TITLE attributes and others – don’t worry about these as they don’t affect the ALT text which is what we’re concerned with here.
This ALT text will be displayed if the image doesn’t load, due to poor internet connection or wrongly referenced image file source; and it’s especially useful for non-visual users including humans (such as blind people who may be browsing the web with a screenreader tool that speaks the content aloud) and robots (such as search engines which rely on ALT text as well as filenames, captions and other content within close proximity of the image in order to determine what the image is about and what the image and page should rank for).
If there are any words written within the image, it’s best practice in SEO and for general accessibility to replicate these words in textual format to form the alt text, rather than creating a description of the image that doesn’t reflect words that are visually seen in the image.
If there’s no words in the image though, for example if it’s a picture of a flower, then best practice is to succinctly describe the image – giving it a brief but descriptive name, for example “Flower” or even better something like “Red Rose” which is more accurate – don’t make this description too longwinded though as it creates a reversed accessibility barrier in that people who can see the image generally won’t be able to read the text, and Google may perceive this as black hat SEO spam in the form of “keyword stuffing” and “hidden text” / “cloaking”.
ALT Attributes and the ALT Text that they contain are also commonly referred to as ALT Tags.