The focus order is logical and intuitive

Design Notes

Design an intuitive keyboard interaction

When people read through a page using a keyboard, the page content should be displayed in an order which makes sense. Make sure that interactive controls such as: links, buttons and form controls are designed so they receive focus in logical order.

Generally speaking, items should receive focus in a left-right, top-bottom order, across screens and devices. When dynamic content appears on the page focus either needs to move to the new content (such as a modal dialog or an error summary) or the new content should be announced (such a single error message or toast) or information about the new content should be announced (such as autocomplete and search results).

Designers and developers should collaborate to ensure coded pages produce an intuitive focus order.

Developer Notes

Ensure the focus order makes sense

Make sure that interactive controls such as: links, buttons and form controls receive focus in logical order. Ensure:

When there is a form error on a page move focus either to an error summary at the top of the page (which links to the fields that are in error) or move focus directly to the first field that has an error

When providing dynamic content in modal dialogs ensure that keyboard focus moves to the dialog by using HTMLElement.focus() and return the focus to the triggering element when the dialog is closed.

When building a single page application and activating a link change the pages content, ensure that focus does not remain on the link, but instead moves to the new page content.

When new content is loaded above a button ensure that focus is moved to that content automatically.

More information

Testing Notes

The sequence of content makes sense

Make sure that interactive controls such as: links, buttons and form controls receive focus in logical order.

Steps to check

Impact range: Low - High

Test type: Manual (with some support from tools)

Tool: ARC Toolkit (Tab order, Show and track focus)

WCAG Reference: Understanding Success Criterion 2.4.3 Focus Order