UtilDojo

Popular

Menu

Color Contrast Checker — WCAG AA & AAA

  • This tool runs entirely in your browser. Nothing you enter or upload is sent to a server.

Preview

Large text, 24px bold

Normal body text at 16px. The quick brown fox jumps over the lazy dog.

Small caption text at 12px.

Contrast ratio
5.76 : 1
Passes AA for body text
  • PassAA, normal text (4.5 : 1)
  • PassAA, large text (3 : 1)
  • FailAAA, normal text (7 : 1)
  • PassAAA, large text (4.5 : 1)
  • PassUI components and graphics (3 : 1)

About this tool

Enter a text colour and a background colour (HEX, rgb() or hsl()) and see the WCAG contrast ratio, plus whether it passes AA and AAA for normal text, large text and user-interface components.

If the pair fails AA for body text, the tool suggests the closest colour — same hue and saturation, adjusted lightness — that reaches 4.5:1, and you can apply it with one click. The preview shows large, normal and small text so you can judge readability yourself.

Contrast is calculated with the WCAG 2 relative-luminance formula, in your browser, with nothing uploaded.

Frequently asked questions

What contrast ratio do I need?

WCAG AA needs 4.5:1 for normal text and 3:1 for large text (about 24px, or 19px bold) and for UI components. AAA needs 7:1 for normal text and 4.5:1 for large text.

Do logos and decorative text have to pass?

WCAG exempts logos, purely decorative elements and inactive controls, but everything people need to read or operate should pass.

Why does the ratio differ slightly from another checker?

Tools differ in rounding. This one rounds down so a result is never shown as passing when it is a hair below the threshold.

Related tools