Editorial team ·
Can you open the accordion without touching the mouse?
A help page puts each question behind a heading. You want the return instructions, so you press Tab until the heading is highlighted. Now comes the useful part of the test. Try opening it, read what appears, and see whether you can move on without losing your place.
Listen for the state as well as the label
- Set up the keyboard route
- Start before the accordion and enter it by Tab.
- Open Returns, then try its link.
- Check both states
- Read the announced state with the panel open and closed.
- Confirm that controls inside a closed panel are out of the Tab order.
Open and close each section by keyboard
On the practice page, there are three question buttons: Delivery, Returns, and Contact. Tab reaches each heading button. Enter or Space on Returns expands its content. Try both keys over separate passes, and check that the original control stays available to close it again.
If the expanded section has a Return request link, check that Tab can reach it. Close Returns and check the collapsed version. Links inside hidden content should be out of that keyboard path.
Read the header with a screen reader in both states. A button for Returns should identify the control and communicate whether the section is expanded. Inspect the browser accessibility tree if the announcement does not change.
Some accordions allow several sections to remain open. Others close one as another opens. Note which behaviour the design uses, then check that it holds up when you switch between two headers quickly.
| Action | Expected in this example |
|---|---|
| Tab to Returns | Visible focus on the Returns button |
| Press Enter | Returns expands and its state changes |
| Tab again | Focus can reach Return request |
| Return to the header and press Space | Returns collapses and the link leaves the Tab order |
Questions and answers
- Must arrows move between accordion headers?
- The WAI accordion pattern treats arrow navigation as optional. Test the controls’ Tab, Enter, and Space behaviour.
- Should focus always jump into the content?
- For this pattern, the header can stay focused when it opens. Check that people can then reach the content.
- How do I show a hidden link still in the Tab order?
- Record which key moves focus to it after you collapse the section, then add the link name to the report.