Skip to content
easeweb
Search topics

Scrollable areas that a keyboard can't scroll

A checkout's terms box scrolls inside a fixed height, but it has no tabindex and nothing focusable in it, so in Safari Tab passes it by and the arrow keys scroll the page instead.

WCAG 2.2
SC 2.1.1A
Required by
Section 508 · EN 301 549 (EU)
Broken .terms { max-height: 10rem; overflow-y: auto; }
The accessibility problem illustrated: Motor:How do I read the rest?
01

The problem

Keyboard users in Safari can't scroll the terms box, so they can't read the returns and refunds terms they are asked to accept.

02

Try it

Press Tab from Email, then use the arrow keys to read the terms down to 6. Refunds.

Can you bring the returns and refunds clauses into view without the mouse, and still reach Place order?

Broken Can you fix this?

BrokenA scroll box with nothing to focus inside

Terms of sale

1. Orders. We accept your order when we email to confirm it.

2. Prices. Prices include tax. The delivery charge is shown before you pay.

3. Delivery. We deliver within 3 to 5 working days.

4. Changes. You can change or cancel your order until we email to say it has been sent.

5. Returns. You can return unused items within 30 days of delivery.

6. Refunds. We refund the card you paid with within 5 working days of receiving the return.

Tab here passes the box by, as Safari does. Chrome 132 and later, Edge and Firefox stop on a box like this by themselves, so test it in Safari.

A recreated demo. The broken version is intentionally inaccessible.

03

The fix

Let the terms flow with the page, or make the box a named Tab stop with a visible ring.

  1. 1Every box that scrolls can be reached with Tab, at every screen width.
  2. 2A box made a Tab stop has a name and a visible focus ring.
  3. 3Never rely on the browser to make a scroll box focusable.
Before A scroll box with nothing to focus inside
<form action="/checkout" method="post">  …  <h2 id="terms-heading">Terms of sale</h2>  <div class="terms">    <p><strong>1. Orders.</strong> We accept your order when we email to confirm it.</p>    …    <p><strong>5. Returns.</strong> You can return unused items within 30 days of delivery.</p>    <p><strong>6. Refunds.</strong> We refund the card you paid with within 5 working days of receiving the return.</p>  </div>  <label>    <input type="checkbox" name="accept-terms" required>    I have read and accept the terms of sale  </label>  <button type="submit">Place order</button></form>
After

A scroll box that Tab can reach, with a name

<form action="/checkout" method="post">  …  <h2 id="terms-heading">Terms of sale</h2>  <div class="terms" tabindex="0" role="region" aria-labelledby="terms-heading">    <p><strong>1. Orders.</strong> We accept your order when we email to confirm it.</p>    …    <p><strong>5. Returns.</strong> You can return unused items within 30 days of delivery.</p>    <p><strong>6. Refunds.</strong> We refund the card you paid with within 5 working days of receiving the return.</p>  </div>  <label>    <input type="checkbox" name="accept-terms" required>    I have read and accept the terms of sale  </label>  <button type="submit">Place order</button></form>

Fixing this with an AI coding assistant? Get this guide as Markdown, or get every guide in your coding agent.

04

Verify the fix

4 checks, no mouse.

Test with: Keyboard, Zoom, Screen reader

0 of 4 checked

Record the OS, browser and assistive-technology versions, the build, the date, and the actual result of each step. Repeat after changing the shared checkout, table or code components.

Limits

This is a starting pattern, not a guarantee for every application. It covers boxes that scroll with the browser's own scrolling. A carousel or a list scrolled by arrow buttons is covered in carousels that keyboard and screen reader users can't use, and a box that clips its text with overflow: hidden when the text is enlarged, with no way to scroll at all, in enlarged text cut off by fixed-height boxes. Test the complete journey in Safari as well as in Chrome, at the widths your visitors use.

This is a recreated teaching example, not a finding about a named client. The code is a starting pattern: test it in your own product. No completed assistive-technology test is claimed here.

Keep this fixed as your code changes.

Turn guides like this into rules your coding agents and CI follow, then have the result retested with a keyboard and screen readers.

How retests work