About this tool
Enter a text color and a background color to see their WCAG 2 contrast ratio and whether they pass AA and AAA for normal text, large text and interface elements. If a pair fails, the tool proposes the closest color with the same hue that does pass. A live preview shows headings, body text and a button in your colors.
How to use Contrast Checker
- Enter or pick the text color.
- Enter or pick the background color.
- Read the ratio and the pass/fail list.
- If it fails, click Use on a suggested fix.
Frequently asked questions
What ratio do I need?
WCAG AA asks for at least 4.5:1 for normal text and 3:1 for large text (24px, or about 18.66px bold) and for UI components. AAA raises text to 7:1 and large text to 4.5:1.
Is the ratio rounded?
It is truncated to two decimals rather than rounded up, so a pair shown as 4.50:1 really meets the 4.5 threshold.
Does it handle transparent colors?
Yes. A translucent text color is blended over the background first, which is how it will appear on screen.