WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Where should focus be on page load?

for

From: Mark Magennis
Date: Dec 6, 2021 4:43AM


Actually, not just interested to hear from screen reader users but keyboard users in general.

-----Original Message-----
From: WebAIM-Forum < <EMAIL REMOVED> > On Behalf Of Mark Magennis
Sent: 06 December 2021 10:30
To: <EMAIL REMOVED>
Subject: [EXTERNAL] [WebAIM] Where should focus be on page load?

I'd be interested in hearing the opinions of screen reader users or those who are very familiar with screen reader users' experiences about where focus should be when a page loads. I see this as a usability issue rather than a compliance one.

The way I've always looked at this is that when a new 'page' is opened - either a new URL or, in a single page application, a new distinct functional chunk (vague I know), focus should normally go to the top of the page. This helps with predictability and consistency. Only in exceptional circumstances should focus be moved to somewhere else such as the start of the unique page content.

In my thinking, exceptional circumstances are when the user is engaged in a predictable workflow, where the current step leaves focus somewhere distant from the content the user will predictably need to read or interact with next. An example is a site search that opens a search results page. It is predictable that after submitting the search the user will want to immediately read the results. It's hard to imagine a scenario when this will not be the case. So when the search results page open, it is helpful to place focus at the start of the results, usually on a results statement such as "Showing 20 of 1,483 results for xxxxx". Other predictable workflows occur within multi-step processes such as purchasing or ticket booking where at each step the user will always want to go to the start of the step instructions or inputs. So it is helpful to place them there when the step is loaded.

Am I looking at this the right way, or is it helpful to place focus at the start of the unique content more often, even on most pages perhaps?

Aside from page loads, content changes with predictable workflows seem to occur whenever hidden content is revealed or new content is added to a page. For example, if a 'Show Table of Contents' button is used to open a content navigation panel should focus be moved to the panel because it is predictable that the user will want to use it (why would they have opened it otherwise)? Or when an 'Add New Record' button in a table toolbar causes a new row to be added to the table containing fields that need to be filled in. It seems predictable that the user will want to immediately fill them in, so should focus always be moved to the first field in the newly added row?

Would be very interested to hear users' preferences. Thanks, Mark

Mark Magennis (he/him)
Senior Accessibility Specialist
Skillsoft | mobile: +353 87 60 60 162
www.skillsoft.com<;http://www.skillsoft.com/>;

[Skillsoft / Sumtotal]