Skip to main content
WCAGrules
Quick navigation

Let users switch nonessential alerts off

SCR14 is a sufficient technique, so an implementation that does what it describes settles the rule it belongs to. What it describes has moved on from what most write-ups say about it. The current technique is not about pop-up dialogs at all. It is a live region with a switch. W3C's worked example is a stock price component. It carries aria-live and aria-atomic, so a screen reader reads the whole component rather than the digit that changed. A pair of buttons flips aria-live between assertive and off. The rule the technique is built around is that nothing non-emergency announces itself on load. Users opt in. The boundary is worth knowing before you cite it, because SCR14 governs announcements you choose to make, not content that moves on its own, and it has nothing to say about a genuine emergency.

How we find it in an audit

Judging whether an interruption is essential is not a machine's job, and no scanner attempts it. So a reviewer spends real time in the interface, logs every announcement it produces unasked, and then goes hunting for the control that stops them. Two checks settle it. Nothing non-emergency announces on load, and there is a mechanism that switches the announcements on and back off again. We note the frequency too, because an update every ten seconds is a different experience from one every ten minutes even when both are switchable.

How affected users experience it

An assertive live region cuts in over whatever a screen reader was reading, mid-sentence, and does it again on the next update. A user filling in an order form loses their place every time. Finding it again costs effort nobody budgeted for. For people with attention or memory disabilities the cost is larger and less visible. One badly timed interruption can take the whole task with it, and the second one arrives before the thread has been picked back up.

Passes vs. fails

Passes: warned, and one press extends. Fails: silent expiry destroys work.

Passes

<div id="price" aria-live="off" aria-atomic="true">142.30</div>
<button onclick="setLive('assertive')">Announce price updates</button>
<button onclick="setLive('off')">Stop announcing them</button>

Fails

<div id="price" aria-live="assertive">142.30</div>
<!-- Announces on load and every ten seconds after. Nothing turns it off. -->

How this gets tested

The W3C publishes test rules that define what a checker looks for here.

Other ways to satisfy this rule

5 guides on this site are filed under 2.2.4 Interruptions. W3C lists this one as sufficient for that rule on its own. Implement it correctly, in a way your readers' software actually supports, and the rule is met.

This guide is our interpretation of W3C technique SCR14: Using scripts to make nonessential alerts optional. W3C publishes its techniques as guidance rather than as the standard, and says so on every one of them. The success criterion is what conformance is measured against, and a technique is one documented way to meet it.

Go somewhere useful

Find tools, resources and your workspace.

29 destinations