Accessibility

7 min read · February 2025

WCAG Color Contrast Guide: Make Your Website Accessible

Approximately 300 million people worldwide have some form of color vision deficiency. Millions more have low vision due to aging, cataracts, or other conditions. If your website's text does not have sufficient color contrast, a significant portion of your audience cannot read it — and in some jurisdictions, that is also a legal problem.

What Is WCAG?

WCAG stands for Web Content Accessibility Guidelines — a set of internationally recognized standards published by the W3C (World Wide Web Consortium). These guidelines define how to make web content accessible to people with disabilities, including visual, auditory, cognitive, and motor disabilities.

The current version is WCAG 2.1, with WCAG 2.2 adding further refinements. Many countries and regions have incorporated WCAG standards into law:

Even if your website is not legally required to comply, accessibility is good practice — it expands your audience, improves SEO, and demonstrates social responsibility.

Understanding Contrast Ratio

Contrast ratio is a mathematical measure of the difference in relative luminance between two colors. It is expressed as a ratio, with 1:1 being identical colors (no contrast) and 21:1 being the maximum contrast (black text on a white background).

The formula uses relative luminance — a measure of how bright a color appears to the human eye, weighted to match how our eyes perceive different wavelengths of light. Green contributes more to perceived brightness than red, which contributes more than blue.

You do not need to understand the mathematics — the SimplyToolbox Color Contrast Checker calculates the ratio automatically from any hex, RGB, or HSL color pair.

WCAG AA vs. AAA Standards

WCAG defines two conformance levels for color contrast:

Level AA (The Minimum Standard)

AA is the standard that most legal requirements reference. The requirements are:

Level AAA (Enhanced Accessibility)

AAA is a higher standard, recommended for applications used by people with severe visual impairments:

AAA is not required by most regulations, but achieving it for body text shows strong commitment to accessibility. Many popular design systems (like Radix UI and Material Design) aim for AAA contrast ratios for text.

Good vs. Bad Contrast: Practical Examples

Fails AA

Light grey on white

#aaaaaa on #ffffff — ratio 2.32:1

White on yellow

#ffffff on #facc15 — ratio 1.08:1

Passes AA

Dark slate on white

#1e293b on #ffffff — ratio 16.0:1

White on indigo

#ffffff on #4f46e5 — ratio 4.6:1

How to Fix Failing Colors

When the checker flags a color pair as failing, here is how to improve it:

Try it free →

Check contrast ratios instantly with AA and AAA compliance badges.

Open Color Contrast Checker

Related Tools