# ARIA Attributes

> Extra labels in the code. They tell screen readers what a part is and does.

**Field:** Design  
**Category:** Accessibility  
**Also known as:** ARIA, Accessible Rich Internet Applications (ARIA), WAI-ARIA, ARIA Roles

## Think of it like

It is like sticky notes on a box that say what is inside. The box is unchanged.

## Definition

ARIA is a set of extra HTML labels that tell helper tools what a part is and what state it is in. It adds roles, like dialog or tab, and states, like open or checked. It only changes what a screen reader says, not how a part looks or acts. The first rule of ARIA is to use a real HTML element when one exists. Wrong ARIA is worse than none.

## Example

A home-made menu button gets one ARIA label. Now a screen reader says Menu, shut. After a press, it says open.

## Example code

```html
<button aria-expanded="false" aria-controls="menu">Menu</button>
<ul id="menu" hidden>...</ul>
```

aria-expanded tells a screen reader whether the menu is open. The script flips it on each press.

## Why it matters

Custom widgets are silent to screen readers without it. With it, they can be described.

## Common mistake

Giving a plain box the role of a button instead of using a real one. The role does not make the keys work.

## Three principles

- **Adds meaning only.** Not looks or behaviour.
- **Real HTML first.** The first rule of ARIA.
- **Wrong is worse than none.** Test with a screen reader.

## Related terms

- [Accessible Name](https://learn.benibix.com/term/design/accessible-name)
- [Screen Reader](https://learn.benibix.com/term/design/screen-reader)
- [Landmark Regions](https://learn.benibix.com/term/design/landmark-regions)
- [Semantic HTML](https://learn.benibix.com/term/development/semantic-html)
- [Live Region](https://learn.benibix.com/term/design/live-region)
- [Accessibility Tree](https://learn.benibix.com/term/design/accessibility-tree)

## Told apart from

- [Semantic HTML vs ARIA Attributes](https://learn.benibix.com/compare/semantic-html-vs-aria): People think ARIA is the way to make a page accessible, and it is not the first step. Semantic HTML comes first: a real button or nav already tells a screen reader what it is. ARIA fills the gaps that no HTML element covers.

## Taught in

- [Semantic HTML Elements](https://learn.benibix.com/learn/development-web/semantic-html-elements): HTML, CSS and JS, 5/14

---

Source: https://learn.benibix.com/term/design/aria
Author: Behnia Zarei (a developer in Vienna, Austria, who builds and teaches data, AI and business intelligence at BENIBIX)
Publisher: BENIBIX Learn (https://learn.benibix.com/)
Last updated: 2026-11-18
Licence: CC BY 4.0 (https://creativecommons.org/licenses/by/4.0/). Quote freely with attribution.
