Developer

Colour Contrast Checker

Calculate the exact WCAG 2.2 contrast ratio for foreground and background colours, review text and UI-component thresholds, and preview the pair locally.

View Developer Tools

Colour values are evaluated locally in your browser and are not uploaded or stored by Tool Teaze.

Foreground colour

Use a 3- or 6-digit hex colour.

Background colour

Use a 3- or 6-digit hex colour.

Contrast result

WCAG 2.2 thresholds use the unrounded calculated ratio.

17.74:1contrast ratio

Large preview text

Normal preview text for paragraphs, labels and interface copy.

UI component outline
Normal text · AAPassMinimum 4.5:1
Normal text · AAAPassMinimum 7:1
Large text · AAPassMinimum 3:1
Large text · AAAPassMinimum 4.5:1
UI components · AAPassMinimum 3:1

Large text means at least 18 pt (24 CSS px) regular, or 14 pt (about 18.7 CSS px) bold.

This automated colour-pair check does not establish full WCAG conformance. Manual review is required for context, states, component boundaries and the rest of the interface.

Colour values are checked entirely in your browser and are not uploaded or stored by Tool Teaze.

What this tool does

This checker applies the WCAG 2.2 relative-luminance formula to two hex colours and reports the exact contrast ratio with AA and AAA text results plus the 3:1 UI-component check.

How to use it

  • Enter or choose foreground and background hex colours.
  • Review the contrast ratio, live preview and each WCAG 2.2 threshold.
  • Swap colours, copy the result summary or reset to the sample pair.

Example input and output

Input: Foreground #111827 on background #FFFFFF

Output: 17.74:1 — passes AA and AAA for normal and large text

Common use cases

  • Checking website text before implementation
  • Reviewing design-system colour pairs
  • Testing borders, controls and graphical interface elements

FAQ

Which WCAG thresholds are checked?

Normal text is checked at 4.5:1 for AA and 7:1 for AAA. Large text is checked at 3:1 for AA and 4.5:1 for AAA. UI components and graphical objects are checked at 3:1 for AA where WCAG 2.2 Success Criterion 1.4.11 applies.

What counts as large text?

WCAG defines large-scale text as at least 18 pt (24 CSS px) regular or 14 pt (about 18.7 CSS px) bold. Other text should use the normal-text thresholds.

Does a passing result guarantee WCAG compliance?

No. This automated check evaluates one opaque colour pair. Manual review is still required for context, interactive states, component boundaries, images, gradients and all other applicable requirements.

Are rounded ratios used for pass or fail?

No. The interface displays two decimal places, but every pass or fail decision uses the full unrounded contrast ratio.

Are transparent colours supported?

No. Enter opaque 3- or 6-digit hex colours. Transparent colours must first be composited against their actual background before checking the resulting colour.

Are my colours uploaded?

No. The calculation and preview run locally in your browser without sending or persisting the colour values.