WCAG Contrast Checker
Test any foreground/background color pair against WCAG 2.2 contrast rules. Shows the ratio, live preview, and pass/fail for normal text, large text, and UI components.
How to use
- 1Enter foreground + background
Any two colors as hex, rgb(), or hsl(). Live preview updates in real time.
- 2Read the contrast ratio
From 1 (identical) to 21 (pure black on pure white).
- 3Check the pass/fail badges
AA / AAA verdicts for normal text, large text, and non-text UI components.
- 4Adjust and re-check
Tweak either color until you hit at least AA 4.5:1 for body text.
Examples
FG #333333 · BG #ffffff
Ratio 12.63:1 · AA ✓ · AAA ✓ · Large text ✓
FG #a0a0a0 · BG #ffffff
Ratio 2.85:1 · AA ✗ · AAA ✗
FG #6366f1 · BG #ffffff
Ratio 4.86:1 · AA ✓ · Large text ✓ · AAA ✗
Frequently asked
WCAG 2.2 AA requires 4.5:1 for normal text and 3:1 for large text (18pt or 14pt bold). AAA requires 7:1 and 4.5:1 respectively. UI components (icons, form borders) need at least 3:1.
WCAG 2.2 AA is the legal baseline in most jurisdictions (US, EU, UK). WCAG 3 will introduce APCA, which is more perceptually accurate but not yet the compliance target.
Perceptual contrast between light greys and white, or between blues and purples, is often much lower than it looks. Always test — trust the numbers, not the eye.
Related tools
- Color ConverterPaste any color in hex, rgb(), rgba(), or hsl() and get it in every other format
- Color Blindness SimulatorSimulate how your colors look to people with color vision deficiency (CVD). Cove
- Color Harmony GeneratorGenerate a palette from any base color using 7 classic color-theory schemes: com
- CSS Color NamesBrowse all 147 CSS3 named colors. Look up a color name from a hex code, or find
- CSS Gradient GeneratorDesign linear, radial, and conic CSS gradients with unlimited color stops. Live