WCAG Contrast Checker
Check WCAG 2.1 color contrast ratios.Runs in this tab.⌘ ↵ runs it
Large Text Sample (18pt+)
Normal text sample — The quick brown fox jumps over the lazy dog.
Small text for detailed reading and interface elements.
Contrast Ratio
How to use WCAG Contrast Checker
- Set Foreground (Text) and Background with the hex fields or the color pickers. The page opens on #1a1a2e and #ffffff.
- Read Contrast Ratio and the four rows: AA Normal Text (4.5:1), AA Large Text (3:1), AAA Normal Text (7:1), and AAA Large Text (4.5:1).
- Click Swap Colors to flip the pair. The preview labels the large sample as "Large Text Sample (18pt+)".
Contrast pairs this checker measures
The ratio uses the WCAG 2 relative luminance formula. WCAG 2.1 and 2.2 use those same numbers for text. The page checks text contrast only.
The default pair
Foreground #1a1a2e on background #ffffff is 17.06:1.
| Check | Threshold | Result |
|---|---|---|
| AA Normal Text | 4.5:1 | Pass |
| AA Large Text | 3:1 | Pass |
| AAA Normal Text | 7:1 | Pass |
| AAA Large Text | 4.5:1 | Pass |
Gray on white, just under 4.5:1
#777777 on #ffffff is 4.48:1.
| Check | Threshold | Result |
|---|---|---|
| AA Normal Text | 4.5:1 | Fail |
| AA Large Text | 3:1 | Pass |
| AAA Normal Text | 7:1 | Fail |
| AAA Large Text | 4.5:1 | Fail |
#767676 on #ffffff is 4.54:1 and passes AA Normal. The two grays look almost the same. The 4.5:1 line is between them.
White text on a blue button
#FFFFFF on #0B5FFF is 5.13:1. That passes AA Normal and AA Large. It fails AAA Normal, which needs 7:1. Swap Colors flips the pair and the ratio stays 5.13:1, because the formula uses the lighter and darker luminance, not which field you typed first.
Large text in the preview is labeled “Large Text Sample (18pt+)”. That matches the WCAG large-text size: 18pt, or 14pt bold. The checker does not apply the 3:1 rule for non-text UI parts, and it does not use APCA or WCAG 3. Colors are hex.
Next step
Turn a click-through into an interactive demo
AtriumKit records your web app once in Chrome and turns every click into a step of a demo you can embed or share. There’s a free plan.
Try AtriumKit freeQuestions
What contrast ratio does WCAG AA require?
What is the difference between WCAG AA and AAA?
Why does #777777 on white fail a color / colour contrast check?
Does this check WCAG 2.2 non-text contrast?
Comments
More in Accessibility
- ARIA Roles Reference
- Alt Text Generator
- Heading Hierarchy Checker
- Readability Score
- Color Safe Palette
- Link Text Checker
- Focus Order Visualizer
Comments