Esta página ainda não foi traduzida para o português, por isso aparece em inglês.

WCAG Color Contrast Checker

Enter a text and background color to get the exact WCAG contrast ratio, pass/fail for every level, an APCA score and one-click fixes that keep your hue.

Atualizado em
Examples:
–
UseMinimumAAAAA
Normal text
below 24px, or below 18.66px bold
4.5:1 · 7:1
Large text
24px+, or 18.66px+ bold
3:1 · 4.5:1
UI components & graphics
icons, input borders, focus indicators
3:1—
APCA (WCAG 3 draft): Lc –
Large text — 24px regular
Large bold text — 18.66px bold

Normal body text at 16px. The quick brown fox jumps over the lazy dog, and readable contrast helps everyone in bright sunlight.

Small print at 13px is where low contrast hurts most.

ButtonInput border

Nearest passing colors

Each suggestion keeps the hue and saturation and changes only the lightness, by the smallest amount that reaches the target.

AdjustSuggestionRatio

Seus dados nunca saem do seu computador. Todo o processamento acontece localmente no navegador.

Como usar: Contrast Checker

  1. Enter the text color and the background color (HEX, rgb(), hsl(), oklch() or a CSS name), or use the color pickers.
  2. Read the contrast ratio and the AA/AAA results for normal text, large text and UI components.
  3. Check the live preview — headings, body copy, small print, a button and an input border.
  4. If a level fails, click Use next to the nearest passing color to apply it, then copy the new HEX into your CSS.

What is a color contrast ratio?

The contrast ratio compares the relative luminance of two colors on a scale from 1:1 (identical) to 21:1 (black on white). The Web Content Accessibility Guidelines (WCAG) use it to decide whether text is readable for people with low vision or color-vision deficiencies — and for anyone reading a phone in bright light. It is also a legal benchmark: accessibility laws such as the European Accessibility Act and the ADA are commonly assessed against WCAG 2.x level AA.

WCAG 2.2 contrast requirements

CriterionLevelNormal textLarge text
1.4.3 Contrast (Minimum)AA4.5:13:1
1.4.6 Contrast (Enhanced)AAA7:14.5:1
1.4.11 Non-text ContrastAA3:1 for UI component boundaries, focus indicators and meaningful icons/graphics

Large text means at least 18 pt (24 px) regular or 14 pt (≈18.66 px) bold. Logos, purely decorative text and the text of disabled controls are exempt.

How the ratio is calculated

Each sRGB channel is linearized (values ≤ 0.04045 are divided by 12.92, others use ((c + 0.055) / 1.055)2.4), then combined into relative luminance: L = 0.2126 R + 0.7152 G + 0.0722 B. The ratio is (Llighter + 0.05) / (Ldarker + 0.05). Thresholds are strict: #777777 on white is 4.47:1 and fails AA, while #767676 reaches 4.54:1 and passes. That’s why this checker truncates rather than rounds the displayed ratio. Semi-transparent text is first blended onto the background, exactly as the browser would paint it.

What is APCA?

The Accessible Perceptual Contrast Algorithm (APCA) is the candidate contrast method for the future WCAG 3. It reports a lightness contrast value Lc from roughly 0 to 106 (negative for light text on dark backgrounds) and accounts for polarity — light-on-dark and dark-on-light are not perceived equally. As a guide, Lc 90 is preferred for body text, Lc 75 is the minimum for body text and Lc 60 for other content text. APCA is still a draft, so meet WCAG 2.x for compliance today and use APCA as a second opinion, especially for dark themes.

Fixing a failing pair

The suggestions table finds the closest color that passes by changing only the HSL lightness of either the text or the background, so your brand hue survives. For darker or lighter variants of a brand color, generate a full tint and shade scale with the Color Converter and test pairs here. In Webflow, the Designer’s Vision preview simulates color-vision deficiencies, but it doesn’t show a ratio — check the exact numbers here before you publish.

Também pesquisado como: color contrast checker, wcag contrast, contrast ratio, accessibility, a11y, aa aaa, apca, color accessibility.

Ferramentas que combinam com: Contrast Checker

  • CSS Gradient Generator — Design a gradient visually — drag color stops, change the angle or type, start from a preset — and copy production-ready CSS with a solid fallback color.
  • Image Alt Checker — Audit every image on a page in one table: alt text status, file size, width/height attributes, format and lazy loading — with filters and CSV export.
  • Box Shadow Generator — Stack multiple shadow layers, tweak offsets, blur, spread and opacity on a live card, then copy the box-shadow or text-shadow CSS.
  • HEX to RGBA Converter — Paste a HEX code, drag the opacity slider and copy the exact CSS you need — legacy rgba(), modern rgb( / alpha) or 8-digit HEX.

Perguntas frequentes

What contrast ratio do I need to pass WCAG AA?
At least 4.5:1 for normal text and 3:1 for large text (24px, or 18.66px bold). User-interface components and meaningful graphics such as icons and input borders also need 3:1 under WCAG 2.1/2.2 criterion 1.4.11.
Does 4.49:1 round up to 4.5:1?
No. WCAG thresholds are exact minimums, so a ratio of 4.499:1 fails AA. This checker truncates the displayed ratio to two decimals to avoid showing a misleading “4.5:1” for a failing pair.
Do disabled buttons, placeholders and logos need enough contrast?
Logos and the text of inactive (disabled) controls are exempt from 1.4.3. Placeholder text is not exempt if it conveys information, so it should meet 4.5:1 — or don’t rely on placeholders as labels.
What is APCA and will it replace the WCAG 2 contrast ratio?
APCA is the perceptual contrast method proposed for WCAG 3. It is more accurate for dark mode and thin fonts, but WCAG 3 is still a draft, so WCAG 2.x ratios remain the requirement for audits and legal compliance.
How do I check contrast for text on a gradient or image?
Measure the lightest (for dark text) or darkest (for light text) area behind the text — that’s the worst case. If it fails, add a solid or semi-transparent overlay behind the text and test the blended color.
Posso instalar o Contrast Checker como um aplicativo da web e usá-lo offline?
Sim. O Contrast Checker é um aplicativo da web instalável (PWA) — instalado a partir do seu navegador, não baixado de uma loja de aplicativos. Clique em “Instalar aplicativo” na parte superior desta página no Chrome ou no Edge (Windows, macOS, Linux, ChromeOS) ou, no Android, use “Compartilhar” → “Adicionar à tela inicial” no iPhone e no iPad, ou “Arquivo” → “Adicionar ao Dock” no Safari 17+ em um Mac. Em seguida, ela se abre em uma janela própria com seu próprio ícone e, como é executada inteiramente no seu navegador, continua funcionando offline. O Firefox no desktop não permite a instalação de aplicativos da web. Como funciona a instalação.

Ferramentas relacionadas