Color contrast checker
Test text and background colors against WCAG, and get a fix when they fail.
Large text looks like this
Normal text looks like this. Read it at arm’s length to judge it the way your visitors will.
| Normal text, AA | needs 4.5:1 | Pass |
|---|---|---|
| Normal text, AAA | needs 7:1 | Fail |
| Large text, AA | needs 3:1 | Pass |
| Large text, AAA | needs 4.5:1 | Pass |
| Icons and UI parts, AA | needs 3:1 | Pass |
How to use it
- Enter your text color and background color as hex values, or use the pickers.
- Read the ratio and the pass or fail result for each kind of text.
- If it fails, use the suggested color, which keeps the same hue and changes only the lightness.
What the numbers mean
Contrast ratios run from 1:1, which is no difference at all, to 21:1, which is black on white. WCAG level AA asks for 4.5:1 for normal text and 3:1 for large text. Level AAA asks for 7:1 and 4.5:1.
Large text means at least 24px, or about 18.7px when bold. Icons, input borders and other interface parts need 3:1 under WCAG 1.4.11.
Why a passing score can still feel hard to read
The formula measures luminance only. Thin fonts, small sizes and strongly saturated pairs such as red on green can feel worse than their number suggests. Treat a pass as the minimum, then read the text on a real phone.
Common questions
Does this use the official WCAG formula?
Yes. It uses the relative luminance and contrast ratio definitions from WCAG 2.
Does order matter?
Not for the ratio. Swapping the two colors gives the same number, though it can change how the text feels.
Do logos need to pass?
WCAG exempts logos and brand names from the text contrast rule.
Related guides
- Color contrast and WCAG, explained without the jargon
What contrast ratios mean, which numbers to aim for and how to fix colors that fail.
- An accessible design checklist for your next website
Ten checks that catch most common accessibility problems before launch.
More free tools
- QR code generator
Create a custom QR code with your colors, shapes and logo, then test that it scans.
- Background remover
Remove the background from a photo right in your browser, then save a PNG.
- Image enhancer
Upscale small photos with AI and fix brightness, sharpness and color.