Keyboard Navigation
Everything must be operable with a keyboard alone, which is the single most load-bearing accessibility requirement.
Definition
WCAG 2.1.1 requires all functionality to be available from a keyboard, and 2.1.2 requires that focus can always move away again. This serves screen reader users, people with motor impairments, people using switch devices or voice control, and a large number of people who simply prefer keyboards.
Craft convention. True because the industry converged on it. Breaking it costs familiarity, not correctness.
On this page
The checks that find most problems
- 1.Put the mouse away and complete the primary task using Tab, Shift+Tab, Enter, Space, Escape and the arrow keys.
- 2.Confirm every interactive element can be reached and activated.
- 3.Confirm focus is always visible, including over sticky headers and inside scroll containers.
- 4.Confirm the tab order follows the visual order.
- 5.Confirm focus never becomes trapped anywhere except a modal dialog, which must be escapable.
- 6.Confirm a skip link exists to bypass repeated navigation.
Expected key behaviour
| Component | Keys |
|---|---|
| Button | Enter and Space activate. |
| Link | Enter activates. |
| Checkbox | Space toggles. |
| Radio group | Arrows move and select within the group. Tab enters and leaves. |
| Tabs | Arrows move between tabs. Tab moves into the panel. |
| Menu | Arrows move, Enter activates, Escape closes, typing jumps to a match. |
| Modal | Focus trapped inside. Escape closes. Focus returns to the trigger. |
| Combobox | Arrows move through options. Enter selects. Escape closes the list. |
Sources
Where a source establishes something narrower than the popular reading of it, the note says so.
Continue from here
Each link says what the connection is, so you can tell a principle from an alternative from a thing people mix this up with.
Applies when you are designing
Relied on by
Entries that assume this is already in place.
- Focus IndicatorsAccessibility
Keyboard access without a visible focus ring is technically operable and practically unusable.
- AccordionComponent
- Date PickerComponent
- MenuComponent
- Modal DialogComponent
- SliderComponent
- TabsComponent
- TooltipComponent
- Bulk ActionsPattern
- Command PalettePattern
- Infinite Scroll and PaginationPattern
- NavigationPattern
- UndoPattern
Often used with
These usually appear in the same screen or the same decision.
- Accessibility InsightsTool
- LinearTool
Check your work
Review passes that test whether this was done properly.
- Accessibility ChecklistChecklist
Short definition
The one-paragraph version, for when that is all you need.
Related concept
Connected closely enough to change how you apply this.
- Accessible NamesAccessibility
- Character Key ShortcutsAccessibility
- Content on Hover or FocusAccessibility
- Focus ManagementAccessibility
- Screen ReadersAccessibility
- WCAG in PracticeAccessibility
- UI to Accessibility AuditAI workflow
- Flexibility and Efficiency of UseHeuristic
- Fitts's LawLaw
- Power Law of PracticeLaw
- Steering LawLaw
- Visual StatesUI foundation
- Accessibility AuditWorkflow
- Design QAWorkflow