Skip to main content
WCAGrules
Quick navigation

Give object elements meaningful fallback content

The object element renders whatever sits between its tags when the embedded thing cannot be shown, so that body is where the text alternative goes. W3C lists H53 as sufficient for 1.1.1 Non-text Content, and for media alternatives when the body holds a link to the alternative rather than the alternative itself. Then it attaches a condition that decides when the technique counts at all. Fallback only reaches a person if the media does not render, so an author can rely on H53 only when they are not relying on the embedded technology's own accessibility. That rules out the modern case people reach for. If your SVG or PDF renders, the fallback never appears, and the accessibility of the SVG or the PDF is what has to carry the rule instead.

How we find it in an audit

An empty object body is the one thing a scanner finds on its own, and it maps exactly onto W3C's single test check. Where there is fallback, we read it, because Your browser cannot display this content is technically an alternative and answers nothing anybody wanted to know.

How affected users experience it

What reaches a person depends on the browser and the content type. Where the object does not render, the body is what they get. Where it does render, they get whatever the embedded thing exposes, which for an untagged PDF or an unlabeled SVG is often nothing. An empty body turns a chart into a hole in the page either way.

Passes vs. fails

Passes: alt text names the product. Fails: the file name is all there is.

Passes

<object data="chart.svg" type="image/svg+xml">
  <p>Line chart. Signups grew from 1,200 in January to 4,800 in June.</p>
</object>

Fails

<object data="chart.svg" type="image/svg+xml"></object>

How this gets tested

The W3C publishes test rules that define what a checker looks for here.

Other ways to satisfy this rule

39 guides on this site are filed under 1.1.1 Non-text Content. W3C lists this one as sufficient for that rule on its own. Implement it correctly, in a way your readers' software actually supports, and the rule is met.

This guide is our interpretation of W3C technique H53: Using the body of the object element. W3C publishes its techniques as guidance rather than as the standard, and says so on every one of them. The success criterion is what conformance is measured against, and a technique is one documented way to meet it.

Go somewhere useful

Find tools, resources and your workspace.

29 destinations