--- url: "https://www.w3.org/WAI/WCAG22/Techniques/aria/ARIA17" titulek: "ARIA17: Using grouping roles to identify related form controls | WAI | W3C" h1: "Technique ARIA17:Using grouping roles to identify related form controls" popis: "" jazyk: "en" kanonicka: "" drobecky: [] zdroj: "live" wayback_snapshot: "" stazeno: "2026-09-14 04:42:32" znaku: 4128 slov: 550 kodovani: "utf-8" sha256: "a785e781743b7c7084ff4585ce48c7d0b3182aeac7f3713d9f392eb479794578" --- # Technique ARIA17:Using grouping roles to identify related form controls ## About this Technique This technique relates to: - [1.3.1 Info and Relationships](https://www.w3.org/WAI/WCAG22/Understanding/info-and-relationships) ( **Sufficient** ) - [3.3.2 Labels or Instructions](https://www.w3.org/WAI/WCAG22/Understanding/labels-or-instructions) ( **Sufficient** when used with [G131: Providing descriptive labels](../general/G131) ) This technique applies to technologies that support [Accessible Rich Internet Applications (WAI-ARIA)](https://www.w3.org/TR/wai-aria/). Techniques are examples of ways to meet Web Content Accessibility Guidelines (WCAG). They are **not required** to meet WCAG. Content can satisfy the normative requirements of WCAG even if it does not use any of the documented techniques. See [About WCAG Techniques](https://www.w3.org/WAI/WCAG22/Techniques/about). ## Description The objective of this technique is to mark up a set of related controls within a form as a group. Any label associated with the group also serves as a common label or qualifier for individual controls in the group. Assistive technologies can indicate the start and end of the group and the group's label as one navigates into and out of the group. This is a viable alternative for grouping form controls programmatically when the user interface's design makes it difficult to employ the `fieldset` / `legend` technique ([H71](../html/H71)). For a group of radio buttons, one should use `role="radiogroup"` instead of `role="group"`. The group can be labeled using `aria-labelledby`. This technique is not meant for wrapping all controls on a form within a single container with `role="group"`. ## Examples ### Example 2: Identifying radio groups This example demonstrates use `role=radiogroup`. Note also that the radio buttons are custom controls with `role=radio`. One may optionally employ CSS to place a border around groups of such fields to visually reinforce the group relationship. The CSS properties are available below the form. ```

Set Alerts for your Account

Send an alert when balance exceeds $3,000

Yes
No

Send an alert when a charge exceeds $250

Yes
No
``` Related CSS Style Definition to place a border around the group of fields: ``` div[role=radiogroup] { border: black thin solid; } ``` Working example: [using grouping roles to identify related form controls](../../working-examples/aria-grouping-related-fields/). Note The script to make the `span` actually work like radio buttons is not included in this example. For a similar, but coded slightly differently, working example, see the ARIA Authoring Practices' [Radio Group Example Using aria-activedescendant](https://www.w3.org/WAI/ARIA/apg/patterns/radio/examples/radio-activedescendant/) example. ## Related Resources *No endorsement implied.* - [ARIA `group` role](https://www.w3.org/TR/wai-aria/#group) - [ARIA `radiogroup` role](https://www.w3.org/TR/wai-aria/#radiogroup) ## Tests ### Procedure For groups of related controls where the individual labels for each control do not provide a sufficient description, and an additional group level description is needed: 1. Check that the group of logically related input or select elements are contained within an element with `role=group` , or `role=radiogroup` depending on the type of elements the group contains. 2. Check that this group has an accessible name defined using `aria-label` or `aria-labelledby` . ### Expected Results - #1 and #2 are true. Back to Top