Contrast Checker
Check whether your text and background colors meet WCAG accessibility contrast standards.
How it works
The Web Content Accessibility Guidelines (WCAG) measure readability with a contrast ratio from 1:1 (identical colors) to 21:1 (black on white). The ratio is computed from each color's relative luminance — roughly, how bright the color appears to the human eye, with green weighted far more heavily than blue because our eyes are most sensitive to it. To pass, normal-sized text needs a ratio of at least 4.5:1 for AA (the legal standard in most places) or 7:1 for AAA; large text (bold 14pt+ or 18pt+) gets a break at 3:1 and 4.5:1 because bigger glyphs are easier to read. Low contrast is one of the most common accessibility failures on the web, and it affects far more people than screen-reader users — anyone reading on a phone in sunlight benefits.
How to use
- Click the Text color picker and choose the color of your text.
- Click the Background color picker and choose the color behind it.
- Look at the preview box — it shows a Large text sample and a Regular body text sample rendered in your two colors.
- Read the Contrast ratio (e.g. 6.7:1) and the four verdict badges: AA and AAA for normal text and large text, each marked pass or fail with the threshold it needed.
Frequently asked questions
What are the WCAG contrast thresholds?
For normal-sized text, AA requires at least 4.5:1 and AAA requires 7:1. Large text (bold 14pt and up, or 18pt and up) is easier to read, so it gets a break: 3:1 for AA and 4.5:1 for AAA. This checker tests all four combinations automatically.
Does the default example pass?
Yes — mostly. White text (#ffffff) on the default blue (#1d4ed8) measures about 6.7:1, which passes AA for normal text and AAA for large text, but falls short of AAA's 7:1 bar for normal text.
How is the ratio calculated?
From each color's relative luminance — how bright it appears to the human eye. Green is weighted far more heavily than blue (coefficients 0.7152 vs 0.0722) because our eyes are most sensitive to green light. The ratio runs from 1:1 (identical colors) to 21:1 (black on white).
Is contrast the whole accessibility story?
No. A passing ratio means the text is legible, but good accessibility also needs real text (not images of text), resizable fonts, keyboard navigation, and sensible heading structure. Use this checker as one step in a larger review.