Color Contrast Checker
Pick foreground and background colors to instantly see the WCAG 2.1 contrast ratio and pass/fail results for AA and AAA levels.
WCAG AA needs a contrast ratio of at least 4.5:1 for normal text and 3:1 for large text (24px, or 18.67px bold).
Use the Color Contrast Checker
Foreground (Text)
Background
Live Preview
12px — The quick brown fox jumps over the lazy dog.
14px — The quick brown fox jumps over the lazy dog.
18px — The quick brown fox jumps over the lazy dog.
24px Bold — Color Contrast Checker
Quick answer
WCAG AA needs a contrast ratio of at least 4.5:1 for normal text and 3:1 for large text (24px, or 18.67px bold). AAA raises that to 7:1 and 4.5:1. Enter two hex colors to get the exact ratio. #767676 is the lightest gray that passes AA on white.
Examples
| Colors | Ratio | AA normal text |
|---|---|---|
| #000000 on white | 21:1 | Pass |
| #333333 on white | 12.63:1 | Pass (AAA too) |
| #595959 on white | 7:1 | Pass (AAA too) |
| #767676 on white | 4.54:1 | Pass |
| #777777 on white | 4.48:1 | Fail |
| #999999 on white | 2.85:1 | Fail |
| White on #FF0000 | 4:1 | Fail (large text passes) |
Test your two colors.
Summary
Pick foreground and background colors to instantly see the WCAG 2.1 contrast ratio and pass/fail results for AA and AAA levels.
How it works
- Choose a foreground (text) color using the color picker or type a HEX code.
- Choose a background color using the second color picker or HEX input.
- Read the contrast ratio and pass/fail badges for WCAG AA and AAA at normal and large text sizes.
- Use the Swap button to reverse foreground and background colors.
- Click Suggest Fix if any level fails — the tool nudges the lighter color lighter (or darker color darker) until the target passes.
Use cases
- Verify UI designs meet WCAG 2.1 AA before shipping to production
- Audit existing web pages for accessibility compliance
- Choose accessible color palettes during brand development