developer.paciellogroup.com

HTML5 Accessibility Chops: title attribute use and abuse

Steve Faulkner

For the past 7 years myself and others have banged on about the trouble with the title attribute in regards to accessibility and usability. Bottom line is that it is not well supported in browsers and its usefulness is severely compromised as a consequence. All browser vendors are aware of the issues in regards to keyboard and touch based interfaces and yet have made no movement or commitment to implement improvements in the 19 years since it was originally specified in HTML.

HTML5 codifies the authoring of inaccessible content

Furthermore we still have the authoritative document for understanding how to use and implement HTML, illustrating and advocating title attribute use in terms that promote and codify inaccessible content. While at the same time the HTML5 specification does not mention the real world documented usage methods for the title attribute that actually help users with disabilities, because the editor of HTML5 refuses to allow it.

The W3C HTML5 Recommendation warns against use of the title attribute:

Warning! Relying on the title attribute is currently discouraged as many user agents do not expose the attribute in an accessible manner as required by this specification (e.g. requiring a pointing device such as a mouse to cause a tooltip to appear, which excludes keyboard-only users and touch-only users, such as anyone with a modern phone or tablet).

Examples of HTML title attribute use and abuse

In the linked document title attribute usage examples I have provided some data of title attribute use on a range of popular sites. The examples illustrate that the title attribute is widely misused.

When to use the title attribute: simplified

  1. Do not use the title attribute, on any element, for any text  that you want all users to have access to.
  2. Only use it to label a form control when the same text is provided as visible text.
  3. Do not use it on a link to provide information that may be important to any user.
  4. If in doubt, read: Using the HTML title attribute

Further reading: