Does the <object> element have alt text?

Goal

Ensure that we are providing text alternatives for people who can’t see custom objects we create.

Why this matters

  • Assistive technology provides the alternative text to people using screen readers or Braille displays.

How to implement

Writer

  • See Image alt text and SVG titles for forging the words themselves.
  • Be sure that the alt text describes the content of the object.
  • If the object represents complex content, write a long description as well.

UX Designer

Developer

  • Add an aria-label or aria-labelledby attribute to the <object> element.

How to test

  1. Right-click and inspect the element in the browser’s developer tools.
  2. Ensure that the <object> has alt text, and that it’s set to a value.
  3. Ensure that the value matches your Writer’s expectations.