Why contrast matters
A brand colour that looks great on your board can become unreadable for a visually impaired person, on a screen in bright sunlight or at a small size. Contrast is the difference in brightness between text and its background. It is also a legal matter for many public websites and a quality criterion for all the others.
The thresholds to remember
The web accessibility rules (WCAG 2.2) measure a contrast ratio from 1:1 (no contrast) to 21:1 (black on white).
| Element | AA level (minimum) | AAA level |
|---|---|---|
| Body text | 4.5:1 | 7:1 |
| Large text (24 px and above, or 19 px bold) | 3:1 | 4.5:1 |
| Icons, borders, interface components | 3:1 | — |
| Example on a white background | Approximate contrast | Verdict |
|---|---|---|
| Black #000000 | 21:1 | Excellent |
| Grey #767676 | 4.5:1 | AA limit for text |
| Yellow #FFFF00 | 1.1:1 | Unreadable |
Test and fix your palette
- List the real pairs: text on background, button and its label, link on background.
- Measure each pair with a contrast checker (browser developer tools include one).
- Darken or lighten the faulty colour: you can keep the hue and change only the lightness.
- Keep two versions of the brand colour: the original for large flat areas, a darker one for text.
- Do not rely on colour alone: add an icon or text for errors and statuses.
Frequently asked questions
What minimum contrast for text?
AA level asks for 4.5:1 for body text and 3:1 for large text. AAA level goes up to 7:1 and 4.5:1.
Does my logo have to meet these ratios?
No, WCAG exempts logos. But it must stay legible on your backgrounds: prepare light, dark and monochrome versions.
How do I measure a contrast?
With an online contrast checker or your browser’s inspector, which shows the ratio of a text and suggests a compliant colour.
Comments
No comments yet. Be the first to react.
Leave a comment