--- title: ARIA Live Regions slug: Web/Accessibility/ARIA/ARIA_Live_Regions translation_of: Web/Accessibility/ARIA/ARIA_Live_Regions ---
In the past, a web page change could only be spoken in entirety which often annoyed a user, or by speaking very little to nothing, making some or all information inaccessible. Until recently, screen readers have not been able to improve this because no standardized markup existed to alert the screen reader to a change. ARIA live regions fill this gap and provide suggestions to screen readers regarding whether and how to interrupt users with a change.
Dynamic content which updates without a page reload is generally either a region or a widget. Simple content changes which are not interactive should be marked as live regions. Below is a list of each related ARIA live region property with a description.
aria-controls: The aria-controls=[IDLIST] is used to associate a control with the regions that it controls. Regions are identified just like an ID in a div, and multiple regions can be associated with a control using a space, e.g. aria-controls="myRegionID1 myRegionsID2".
Normally, only aria-live="polite" is used. Any region which receives updates that are important for the user to receive, but not so rapid as to be annoying, should receive this attribute. The screen reader will speak changes whenever the user is idle.
For regions which are not important, or would be annoying because of rapid updates or other reasons, silence them with aria-live="off".
A website specializing in providing information about birds provides a drop down box. When a bird is selected from the drop down, a region on the page is updated with details about the type of bird selected.
<select size="1" id="bird-selector" aria-controls="bird-info"><option> .... </select>
<div role="region" id="bird-info" aria-live="polite">
As the user selects a new bird, the info is spoken. Because "polite" is chosen, the screen reader will wait until the user pauses. Thus, moving down the list will not speak every bird the user visits, only the one finally chosen.
In the following well-known predefined cases it is better to use a specific provided "live region role":
Role | Description | Compatibility Notes |
---|---|---|
log | Chat, error, game or other type of log | To maximize compatibility, add a redundant aria-live="polite" when using this role. |
status | A status bar or area of the screen that provides an updated status of some kind. Screen reader users have a special command to read the current status. | To maximize compatibility, add a redundant aria-live="polite" when using this role. |
alert | Error or warning message that flashes on the screen. Alerts are particularly important for client side validation notices to users. (TBD: link to ARIA form tutorial with aria info) | To maximize compatibility, some people recommend adding a redundant aria-live="assertive" when using this role. However, adding both aria-live and role=alert causes double speaking issues in VoiceOver on iOS. |
progressbar | A hybrid between a widget and a live region. Use this with aria-valuemin, aria-valuenow and aria-valuemax. (TBD: add more info here). | |
marquee | for text which scrolls, such as a stock ticker. | |
timer | or any kind of timer or clock, such as a countdown timer or stopwatch readout. |
(TBD: what is supported where?)
A chat site would like to display a list of users currently logged on. Display a list of users where a user's log-in and log-out status will be reflected dynamically (without a page reload).
<ul id="roster" aria-live="polite" aria-relevant="additions removals"> <!-- use JavaScript to add remove users here--> </ul>
Breakdown of ARIA live properties:
TBD: Realistic use case for aria-atomic="true"