After closing exposed content, should focus return to the UI component that exposed it?

Question

After exposed content is closed, does focus need to move back to the UI component that exposed it?

Answer

Upon closing revealed content, focus should move back to the component which revealed the content (most often this is a button element). When exposed content is closed, for example a modal dialog, the input focus must move back to the component that exposed the modal dialog.

For more information on focus order, check out the Keyboard Navigation & Focus Management course from Accessible Web.

Free Tools to Continue Learning

Accessible Web Company Logo

Accessible Web RAMP

Monitor your website and manage your progress towards WCAG conformance.

Accessible Web Company Logo

Accessible Web Academy

Career specific courses to help power up your accessibility knowledge.