Color Contrast Checker (WCAG)
Enter a text colour and a background colour to see the contrast ratio and whether it passes WCAG 2.2 for normal text, large text and interface components. If it fails, the tool suggests the closest colour that passes.
How to use this tool
- Enter or pick the text and background colours.
- Read the ratio and the pass or fail results.
- Use the suggested colour if it fails.
How it works
Contrast ratio = (L1 + 0.05) ÷ (L2 + 0.05), where L is the relative luminance defined by WCAG 2.2 for sRGB. Thresholds: 4.5:1 normal text AA, 3:1 large text AA (18.66 px bold or 24 px), 7:1 and 4.5:1 for AAA, 3:1 for UI components and graphics (WCAG 1.4.11). Transparent colours are blended over the background first. Suggestions adjust lightness only, keeping hue and saturation.
Limitations
- Contrast is one part of readability; font size, weight and colour blindness also matter.
Privacy and data
Everything happens in your browser. Nothing you enter is sent to our server.