Color Contrast Checker

Make sure your text is easy to read for everyone. Enter two colors to get the WCAG contrast ratio, pass/fail results and a better color if needed.

Loading tool…

How to use the Color Contrast Checker

  1. Enter the text and background colors (HEX, RGB, HSL, a name, or use the pickers).
  2. Read the contrast ratio and the AA/AAA pass or fail results.
  3. If it fails, pick a target and tap “Use this” on the suggested color.

Uses the WCAG 2.x relative-luminance formula. Transparent colors are blended over the background (and the background over white).

Frequently asked questions

What contrast ratio do I need?

WCAG AA needs 4.5:1 for normal text and 3:1 for large text and UI parts like buttons and icons. AAA needs 7:1 for normal text and 4.5:1 for large text.

What counts as large text?

At least 24px (18pt) regular, or 18.66px (14pt) bold.

Why does 4.49:1 fail?

WCAG does not allow rounding up. The tool cuts the ratio to 2 decimals and tests the exact value, so 4.49:1 does not meet the 4.5:1 rule.

How does the suggestion work?

It keeps the hue and saturation of your text color and makes it lighter or darker by the smallest amount that reaches your target.