A HTML attribute used to provide an alternative text for something, often images.

For SEO, it is critically important that as many images as possible (and relevant) have alt texts. Search engines cannot visually see your images, so they rely entirely on your alt text to figure out what the image is about.

For accessibility, it is equally important that all relevant images have descriptive texts. This helps screen readers inform visitors who might not be able to see your image, what an image is about.

Example:

<img src="image.png" alt="A car parked next to a bus stop.">

Tips:

  • You are free to write what you want, as long as it is relevant.
  • Do not add keywords just to boost your SEO, search engines will see right through it.
  • With punctuation, you can end with a period, or leave it open, either works.
  • Note that the alt text will be displayed if the image cannot be displayed for some reason, such as the image not being available, or if the visitor is using a text-only screen reader.