Color Contrast Checker

Check the WCAG contrast ratio between any two colors — instant AA/AAA pass/fail badges.

A free color contrast checker: enter a text (foreground) color and a background color and get the exact contrast ratio, pass/fail badges for AA and AAA at both normal and large text sizes, a non-text/UI-component check, and — if the pair fails — a one-click suggestion for a passing shade. Runs entirely in your browser.

Examples:

Contrast ratio

:1

Non-text / UI components (3:1):

Large text preview

Normal text preview — roughly how body copy at 16px will read against this background.

Fix a failing pair

This pair already passes the selected target.

Frequently asked questions

WCAG 2.1 sets three thresholds: 4.5:1 for normal text at AA (the widely-required baseline), 3:1 for large text at AA and for non-text UI components, and 7:1 for normal text at the stricter AAA level. Higher is always more readable — 21:1 (pure black on pure white) is the maximum possible.
Large text is defined as at least 18pt (24px) at regular weight, or at least 14pt (about 18.66px) at bold weight. Large text gets a lower contrast requirement (3:1 for AA, 4.5:1 for AAA) because bigger, bolder strokes stay legible at lower contrast than small body copy does.
AA is the level referenced by most accessibility laws and standards (ADA, Section 508, EN 301 549) and is the practical baseline to hit. AAA is stricter and recommended where you can get it, but isn't usually a hard requirement — treat it as a stretch goal, especially for body text.
No. This tool measures the WCAG luminance-contrast ratio between two colors, which is a different (and mandatory) accessibility requirement from color-vision-deficiency simulation. A pair can pass every contrast target here and still be hard to distinguish for some forms of color blindness if color alone is used to convey meaning — pair contrast with a dedicated CVD simulator if that's a concern.
The WCAG formula assumes two solid, opaque colors. If either color has alpha, its effective appearance depends on whatever is rendered behind it — flatten a semi-transparent color against its actual backdrop first, then check the resulting solid color here.
WCAG 1.4.11 (Non-text Contrast) requires a 3:1 ratio for the visual boundaries of UI components — like input borders, button outlines, and icons — and for graphics that convey meaning, against their adjacent color. It's separate from the text-contrast rules and is checked automatically alongside them here.
It steps the lightness of whichever side you choose to adjust — text or background — up or down in the perceptually-uniform OKLCH color space, in small increments, until the pair reaches your selected target ratio. The result is clamped back into the sRGB gamut so it's always a real, displayable color.
Yes, completely free, and no. Every calculation runs locally in your browser using JavaScript — your colors are never sent to a server, logged, or stored.