WCAG contrast requirements
| Level | Normal text | Large text (24px, or 18.66px bold) | UI components & icons |
|---|---|---|---|
| AA | 4.5:1 | 3:1 | 3:1 |
| AAA | 7:1 | 4.5:1 | — |
The ratio compares the relative luminance of the two colors, from 1:1 (same color) to 21:1 (black on white). AA is the level required by most accessibility laws, including the European Accessibility Act (in force since June 2025) and ADA guidance in the US.
FAQ
How does the “closest passing color” work?
It keeps the hue and chroma of your text color in OKLCH and only changes lightness until the ratio passes — so your brand color stays recognizable.
Is #767676 on white accessible?
Yes: 4.54:1, the lightest gray that passes AA for normal text on white.
Does this include APCA?
No — APCA is a candidate for future WCAG 3; legal requirements today use the WCAG 2 ratio shown here.