Color Contrast Checker
Pick a text color and a background color — see the WCAG contrast ratio and whether the pair passes AA and AAA, for normal and large text.
Large text — headings and big UI labels
Normal text — body copy like this sentence. If this is hard to read, the combination will be hard to read on your site too.
| AA — normal text (needs 4.5:1) | – |
| AA — large text (needs 3:1) | – |
| AAA — normal text (needs 7:1) | – |
| AAA — large text (needs 4.5:1) | – |
How to use
- Set the text color and the background color, using the color pickers or by typing HEX values.
- Read the ratio and the AA / AAA verdicts — they update as you type.
- If a verdict fails, darken the text or lighten the background (or the other way round) until it passes. The swap button flips the pair when you want to test the inverse.
Example
Mid-gray text such as #777777 on white gives a ratio of about 4.48:1 — just short of the 4.5:1 that AA requires for body text, which is why so much gray web text is quietly hard to read. Darkening it one step to #767676 reaches about 4.54:1 and passes. Black on white is the maximum, 21:1.
FAQ
What contrast ratio do I need for WCAG AA?
WCAG AA requires at least 4.5:1 for normal text and 3:1 for large text (24px or larger, or 19px or larger if bold). AAA requires 7:1 for normal text and 4.5:1 for large text.
How is the contrast ratio calculated?
Each color is converted to its relative luminance using the sRGB formula from the WCAG specification, and the ratio is (lighter + 0.05) divided by (darker + 0.05). The maximum possible ratio is 21:1, for black on white.
What counts as "large text"?
In WCAG terms, large text is at least 24px (18pt), or at least 19px (14pt) if it is bold. Headings usually qualify; body text and small UI labels do not.
Is anything sent to a server?
No. The check runs entirely in your browser. The colors you pick are never uploaded or stored.