|
Developer Utilities 100% Client-Side · 0 Bytes Sent to Server Instant In-Memory Execution

Color Contrast Checker (WCAG)

Free online Color Contrast Checker and WCAG contrast ratio analyzer. Test text and background color combinations for WCAG 2.1 Level AA and AAA accessibility compliance, ADA requirements, and UI readability with real-time interactive previews.

WCAG 2.1 & 2.2 Color Contrast Compliance Analyzer

Test foreground and background color combinations against official Web Content Accessibility Guidelines.

Live Color Blindness & Visual Preview Box

Inspect how your selected palette appears across different types of color vision deficiencies in real time.

Perceived in NORMAL (7.29:1)Text: #065f46 | Background: #ecfdf5

Preview Headline & Interactive Typography

This live visual sandbox demonstrates exactly how text, borders, buttons, and hyperlinks render for people with standard vision. Adequate luminance contrast guarantees high readability.

Hyperlink Preview
Normal Text (AA)Minimum 4.5:1 ratio
Pass AA
Normal Text (AAA)Enhanced 7.0:1 ratio
Pass AAA
Large Text (AA)18pt+ or 14pt bold (3.0:1)
Pass AA
UI Controls & IconsWCAG 2.1 Non-text (3.0:1)
Pass (3.0+)
Calculated Luminance Contrast Ratio

7.29 : 1

Verified Accessible Color Presets

Click to apply palette

Step-by-Step Instructions

1

Enter Foreground & Background Colors

Input text color and background color using Hex, RGB, HSL, or color picker.

2

Review Contrast Ratio

Evaluate calculated luminance contrast ratio (ranging from 1:1 to 21:1).

3

Check WCAG 2.1 / 2.2 Compliance Levels

Review Pass/Fail status for Level AA and Level AAA standards across Normal Text, Large Text, and UI Components.

4

Use Auto-Adjust Color Fixer

Automatically adjust color lightness/darkness with 1 click to achieve guaranteed compliance.

Key Features & Capabilities

  • WCAG 2.1 & 2.2 relative luminance formula: $L = 0.2126 R + 0.7152 G + 0.0722 B$ and contrast ratio: $\frac{L_1 + 0.05}{L_2 + 0.05}$
  • Compliance verification for Level AA (4.5:1 normal text, 3:1 large text) and Level AAA (7:1 normal text, 4.5:1 large text)
  • UI component & graphical object contrast check (3:1 minimum requirement for inputs, buttons, and borders)
  • Interactive text size preview simulating typography on desktop and mobile viewports

Frequently Asked Questions

What is the WCAG contrast ratio requirement for Level AA vs Level AAA?

Under Web Content Accessibility Guidelines (WCAG 2.1/2.2): **Level AA**: requires at least **4.5:1** for regular text (<18pt / <14pt bold), **3.0:1** for large text (≥18pt or ≥14pt bold), and **3.0:1** for UI controls/borders. **Level AAA**: requires at least **7.0:1** for regular text and **4.5:1** for large text.

How is relative luminance calculated for color contrast?

Relative luminance ($L$) calculates the relative brightness of any point in a colorspace normalized to 0 for darkest black and 1 for lightest white. Contrast ratio is computed as: $\text{Ratio} = \frac{L_1 + 0.05}{L_2 + 0.05}$, where $L_1$ is the relative luminance of the lighter color and $L_2$ is the relative luminance of the darker color.

Why is 3:1 contrast required for non-text UI components?

WCAG Success Criterion 1.4.11 requires a 3:1 minimum contrast ratio for user interface components (button borders, form input outlines, toggle switches, active focus indicators). This ensures low-vision users can identify interactive clickable controls on the screen.

What text is considered 'Large Text' under WCAG guidelines?

Large text is defined as text that is at least **18pt (24px)** in standard font weight, or at least **14pt (18.66px)** in **bold** font weight (or equivalent font weight 700+).

Discover complementary online tools in the same workflow.