How to write an img alt tag


Written on Mar 2 2023
updated on Mar 6 2023
🖧
internet

The img alt tag is used by internet search engines for indexing and accessibility. It should be written in short, succinct language. Accessibility readers will use this text and relay it to the user.

David Bowie Rome 390 Snowboard BindingsWicked cool

This image has an alt tag of "David Bowie Rome 390 Snowboard Bindings" which succinctly describes the photo. Make sure to provide just enough detail in a short sentence.

Not only does the img alt tag provide text for the image if it can't be displayed, it is also used in SEO and accessibility

If you can't or don't want to view the internet visually, the alt property of the img tag will provide a description of your image. Remember that the screen reader is telling a story, and your alt tags should provide context for this story.

Most algoritms will not be visually inspecting your images until AI becomes a "little bit better". To help with this we can use the alt property to help index our websites.