WebToolsPlanet
Color Tools

WCAG Color Contrast Checker for Text, Buttons, Icons & UI Components

Check foreground and background color contrast ratios for WCAG 2.2 AA and AAA. Test text, buttons, icons, UI components and get accessible color feedback instantly.

WCAG 2.2 Contrast Checks100% FreeNo Sign UpPrivate & SecureClient Side Processing

Last updated: May 15, 2026

Client-Side Processing
Input Data Stays on Device
Instant Local Execution
HEX, RGB, RGBA, HSL and HSLA inputOpacity blended against white canvasNormal text, large text and UI component checks

Find this tool useful? Support the project to keep it free!

Buy me a coffee

What is Color Contrast Checker?

Color Contrast Checker measures how readable a foreground color is against a background color and compares that result with WCAG 2.2 accessibility thresholds. It supports HEX, RGB, RGBA, HSL, and HSLA colors, checks AA and AAA levels, and tests normal text, large text, and non-text UI components in one place.

It is not only for formal audits. Designers, developers, and accessibility reviewers use contrast checks during mockups, component reviews, and brand updates because a color pair that looks polished in a design file can still fail for small text, muted states, or lower-vision users. You can also test semi-transparent colors with opacity blending, compare a full palette matrix at once, pick colors from screenshots, and export results as CSS variables or Tailwind classes.

How to Use Color Contrast Checker

1

Enter a foreground color (text, icon, or border) using HEX, RGB, RGBA, HSL, or HSLA

2

Enter a background color in the same field

3

Read the contrast ratio and WCAG AA/AAA pass or fail result instantly

4

Switch tabs to Preview UI components, see Improve suggestions, or copy Developer output

5

Adjust colors or use the Improve tab suggestions until your pair meets the required level

6

Copy the result, share a link, or export as CSS variables or a PNG report

Common Use Cases

  • Designers checking whether body text, helper text, and button labels stay readable across a UI system.
  • Accessibility reviewers validating AA or AAA requirements before a release goes live.
  • Brand teams testing whether marketing palette colors can be reused safely in product interfaces.
  • Frontend developers catching low-contrast hover, disabled, and secondary states before they reach QA.

Example Input and Output

The same brand color can pass for large headings but fail for body copy, which is why testing exact pairs matters.

Color pair
Foreground: #1f2937
Background: #f9fafb
Text size: normal body text
Contrast result
Contrast ratio: 14.05:1
WCAG AA: Pass
WCAG AAA: Pass
Large text: Pass

Accessibility

AA and AAA thresholds are not interchangeable. A pair that works for a large hero heading may still fail for smaller body text or muted helper labels.

Workflow tip

Test hover, disabled, and secondary button states too. Teams often validate primary colors but miss lower-contrast UI states introduced later.

Frequently Asked Questions

What is color contrast and why is it important?
Color contrast is the luminance difference between a foreground color and its background. Strong contrast makes text, icons, and controls easier to read for everyone, especially people with low vision.
What is the minimum contrast ratio for normal text?
WCAG AA requires at least 4.5:1 for normal text. AAA requires 7:1 for normal text when you need a stricter readability target.
What is the difference between AA and AAA?
AA is the common accessibility baseline for digital products. AAA is stricter and is usually used for high-readability interfaces or important long-form reading experiences.
What is large text in WCAG?
Large text means at least 18pt / 24px regular text, or 14pt / 18.66px bold text. Large text can pass AA at 3:1 because bigger letters are easier to read.
Does this tool check contrast for UI components and icons?
Yes. The checker includes the WCAG 3:1 non-text threshold for meaningful buttons, icons, input borders, focus rings, toggles, chart marks, and similar UI components.
How do I check contrast for semi-transparent colors?
Paste RGBA or HSLA colors, or use the opacity sliders. The checker blends the visible color before calculating the final contrast ratio.
Can this tool scan my website for contrast issues?
Not yet. This page checks exact color pairs, palettes, and uploaded screenshots locally. A real website scanner is planned as a separate workflow when it is ready.
Is my data or uploaded image stored anywhere?
Uploaded images are not uploaded or stored by WebToolsPlanet. Saved palettes and recent checks use browser localStorage on your device, and feature-use analytics do not include your color values, images, or report contents.
Why does a color pass on one background but fail on another?
Contrast depends on the exact foreground and background pair. A small background change can lower the ratio enough for normal text to fail.
What is the highest possible contrast ratio?
The highest WCAG contrast ratio is 21:1, produced by pure black against pure white or the reverse.