Skip to main content
Version: v6

Image button has non-empty accessible name

Image button has non-empty accessible name — rule summary
FieldValue
Rule codeImagebutton_Name_Missing
WCAG conformance levelA
WCAG success criterion1.1.1 Non-text Content
Must be fixed at sourceNo

Description

Each image button element should have non-empty accessible names. An accessible name allows users to understand the purpose of the image button. The accessible name can be provided through the alt, aria-label, title attributes, or by using aria-labelledby to reference another element with a name.

How to fix

Ensure that all image buttons have an accessible name using one of the following methods:

<input type="image" src="/path/to/icon.png" alt="Search" />
<input type="image" src="/path/to/icon.png" aria-label="Search" />
<input type="image" src="/path/to/icon.png" title="Search" />
<input type="image" src="/path/to/icon.png" aria-labelledby="labelId" />
<div id="labelId">Search</div>

If an image button lacks an accessible name, it is likely to be skipped or misunderstood.