The starting colors
You enter
- Text
- #172033
- Background
- #FFFFFF
You get
- Ratio
- 16.27:1
- Aa normal
- Pass
- Aa large
- Pass
- Aaa normal
- Pass
Dark text on white is far above every threshold, including 7:1 for AAA normal text.
Run through the tool’s own code.
Design tool
Choose text and background colors to see their contrast ratio and WCAG result.
Change either color to check readability. WCAG thresholds are guidance for this color pair only.
About this tool
The checker calculates the WCAG contrast ratio for opaque sRGB colors. It helps review text readability but does not certify an entire page or replace an accessibility audit.
Guide
The Color Contrast Checker compares a text color with a background color and shows their contrast ratio, from 1:1 to 21:1. It then says if the pair passes the WCAG thresholds for normal text at AA, large text at AA and normal text at AAA. You pick both colors with a color picker. It checks only two plain colors, so it cannot say that a whole page is accessible.
Dark text on white is far above every threshold, including 7:1 for AAA normal text.
Run through the tool’s own code.
One step in grey moves the ratio across the 4.5:1 line for normal text. The second grey still passes for large text, which needs only 3:1.
Run through the tool’s own code.
Pure red on white reaches about 4:1. That is enough for large text but not for body text. The ratio is the same if you swap the two colors.
Run through the tool’s own code.
The real ratio is about 4.4995. The tool shows two decimals, so it reads 4.50, but it compares the unrounded number with 4.5. WCAG says the computed value is not rounded, so this is correct, though it looks odd.
Run through the tool’s own code.
Common questions
WCAG 2.2 level AA asks for at least 4.5:1 for normal text and 3:1 for large text. Level AAA asks for 7:1 for normal text and 4.5:1 for large text. Logos and purely decorative text have no requirement.
It is (L1 + 0.05) divided by (L2 + 0.05), where L1 is the relative luminance of the lighter color and L2 of the darker one. Relative luminance weighs red, green and blue after an sRGB adjustment. The result runs from 1 to 21.
WCAG defines large-scale text as at least 18 point, or 14 point and bold. That is about 24 pixels, or about 18.7 pixels bold, in a typical browser. The tool does not ask your font size, so decide this yourself.
The display rounds to two decimals, but the test uses the exact number. A pair that is really 4.4995 shows 4.50 and fails AA for normal text. WCAG says not to round up the ratio before comparing.
No. It means this one pair of colors meets a rule. Accessibility also depends on layout, text size, controls, keyboard use, images and more. The tool is no substitute for a full accessibility audit.
Not with this tool. It takes one solid text color and one solid background color. For an image, check the worst spot behind the text by sampling its color, or add a solid panel behind the text.
No. The ratio is worked out in your browser and the page says nothing is uploaded. Note the hex values yourself if you want to keep them.
WCAG AA requires 4.5:1 for normal text and 3:1 for large text. AAA requires 7:1 for normal text and 4.5:1 for large text.
No. It checks only the two selected colors. Accessibility also depends on layout, text, controls and other factors.