Blog Post

Alt Attribute

Alt Attribute: an alt attribute is a feature used in HTML and XHTML documents to help blind internet users and most major search engines distinguish what is being displayed in an image. Essentially, alt attributes specify alternative text, or alt text, which is rendered when the user or web crawler cannot discern an element like a photo or picture. It is often used by screen reader software to be read aloud to blind users who are reading a web page.

Contrary to popular belief, alt attributes do not have to literally describe the image to which they are applied. Instead, they are intended to help screen readers and search engines understand the function of an object in an image by providing an equivalent text. For example, an image of a stop sign will typically be described by the alt text "Stop!", unless the image is intended to show what a stop sign looks like, in which case the color, shape and other qualities will be written in alt text instead. For this reason, the World Wide Web Consortium (W3C) recommends that decorative images which convey no information use CSS instead.