A11yvanto.online Request an Accessibility Audit

Guide

Colour Contrast Explained

Contrast is one of the easiest accessibility issues to measure. Here is what the ratios mean, how often low contrast turns up and how to fix a palette that fails.

By Benjamin Reed. Updated 3 November 2026. About 6 minutes to read.

Short answer: WCAG asks for a contrast ratio of at least 4.5 to 1 between normal text and its background, and 3 to 1 for large text, which means at least 18 point or 14 point bold. Interface parts such as input borders, icons that carry meaning and focus indicators need at least 3 to 1 against what is next to them. Ratios run from 1 to 1 (no contrast) to 21 to 1 (black on white).

What a contrast ratio is

A contrast ratio compares how light two colours are, using a formula based on relative luminance. The result runs from 1 to 1, when the colours are identical, to 21 to 1, for black on white. The formula weights green most heavily and blue least, because that is how human eyes respond to light, which is why some colours that look strong, like a bright blue, can still fail against white.

The ratio does not care about hue. Red on green might look striking but have very little difference in lightness, and people with some forms of colour blindness may see almost none.

Low contrast is also widespread. WebAIM's automated scan of the top one million home pages, a secondary source run with automated tools that cannot detect every issue, found text below the WCAG AA thresholds on 83.9 per cent of home pages in February 2026 and reported it as the most commonly detected issue.[1]

Text contrast: 4.5 to 1 and 3 to 1

WCAG 2.2 success criterion 1.4.3 Contrast (Minimum) says the visual presentation of text and images of text has a contrast ratio of at least 4.5 to 1, with exceptions.[2] The main exception is large-scale text, which needs at least 3 to 1. WCAG defines large-scale text as at least 18 point, or 14 point bold.[2] In CSS terms that is roughly 24 pixels for regular weight and about 18.7 pixels for bold.

Other exceptions cover text that is purely decorative, text that is part of an inactive control, and text in logos. Disabled buttons are an interesting case: the exception means they do not have to meet the ratio, but if people cannot see that a button exists at all, it may still cause confusion.

WCAG contrast minimums at a glance
WhatMinimum ratioWCAG criterion
Normal text4.5 to 11.4.3 (AA)
Large text (18pt, or 14pt bold)3 to 11.4.3 (AA)
Input borders, meaningful icons, focus indicators3 to 1 against adjacent colours1.4.11 (AA)
Normal text, enhanced7 to 11.4.6 (AAA)

Non-text contrast

Criterion 1.4.11 Non-text Contrast asks for at least 3 to 1 against adjacent colours for user interface components and graphical objects needed to understand content.[2] In practice that covers:

  • the border of a text field, if the border is what shows people where to type;
  • icons that act as buttons, such as a magnifying glass for search;
  • focus indicators, so people can see where they are on the page;
  • the lines and segments of a chart that carry information.

Pale grey input borders on white are a very common failure. A field that looks elegant in a design file can be almost invisible to someone with low vision.

Do not rely on colour alone

Contrast is one rule; Use of Color is another. Colour should never be the only way information is shown. Links within paragraphs should be underlined or otherwise distinguished, not only coloured. Errors should have text, not only a red border. Charts should use labels or patterns as well as colour.

How to fix a palette that fails

Brand colours often fail when used for text. That does not mean abandoning them:

  1. Find the nearest passing shade. Darken the colour for use on light backgrounds, or lighten it on dark ones, until it reaches 4.5 to 1. The difference is often hard to notice.
  2. Use the original for large or decorative things. A brand colour that reaches 3 to 1 can still be used for large headings, illustrations and backgrounds.
  3. Flip the text colour. White text on a mid-tone button may fail where dark text on the same button passes. The lime buttons on this site use near-black text for exactly that reason.
  4. Write the rules down. A palette page that says which colour may be used for what stops the problem coming back.

Text on images and gradients

Text over photos and gradients is hard to judge, because contrast changes across the image. Measure the lightest part behind the text. The reliable fixes are a solid or semi-transparent panel behind the text, a darker overlay on the image, or moving the text off the image.

How to measure

Use a contrast checker with the exact colour values from your CSS or design file, such as our contrast checker, which uses the WCAG formula. Do not judge by eye or from a screenshot, because screens and compression change colours. Check every state: normal, hover, focus, visited, disabled and error.

Dark mode, themes and states

Many sites now offer a dark theme, or follow the visitor's operating system setting. Each theme is a separate palette and needs its own contrast check. A link blue that passes comfortably on white often fails on a dark navy background, and a pale grey that works as secondary text in dark mode can vanish in light mode. Treat every theme as its own set of colour pairs.

Focus rings need the same care: one that is bright on a light section can disappear on a dark one. On this site the focus outline changes colour between light and dark sections for that reason, so it keeps at least 3 to 1 against both.[2] Hover, visited and disabled states are covered in the design system section below.

The failures we look for first

When you review a palette, these are the patterns worth checking first:

  • Light grey body text on white, chosen to look soft. Text in the mid greys often falls below 4.5 to 1.
  • White text on brand colours such as orange, yellow, light green or sky blue, which are too light for small white text.
  • Placeholder and hint text styled in a very pale grey.
  • Input borders drawn in a grey too light to show where a field is.
  • Text over hero images where part of the photo is as light as the text.
  • Footers with muted text on dark backgrounds that slipped through review.
  • Error and success messages in red or green text that is too light, or that relies on colour alone.

Each of these can be fixed by adjusting one colour token, which is why palette rules are worth setting early. Our inclusive design service includes this review.

Building contrast into a design system

The most reliable way to keep contrast right is to decide it once, in the design system, rather than page by page. Give every colour a role, such as body text, muted text, link, border, focus ring and error, and test each role against every background it may sit on. Record the measured ratio beside the colour, so anyone choosing it later can see whether it passes.

Muted text is an easy place for a palette to slip. A grey chosen for captions or helper text can drift lighter with each redesign until it no longer reaches 4.5 to 1. Fixing the token fixes every use at once.

Check the states too. Hover, active, visited and disabled colours each need thought. WCAG does not set a contrast minimum for disabled controls, but they still need to look disabled, and anything people must read to use the page should meet the normal ratio.[2]

Questions about contrast

Does contrast apply to placeholder text?

Yes. If placeholder text conveys information, it is text and needs 4.5 to 1. Many placeholder styles fail, which is one more reason not to use placeholders as labels.

Is 4.49 to 1 close enough?

No. The WCAG threshold is a minimum, and checkers round in different ways. Aim a little above it so small rendering differences do not tip a colour under.

Do logos need to meet contrast?

Text that is part of a logo or brand name is exempt from the text contrast criterion.

Sources

Sources checked on 3 November 2026.

  1. Secondary source. The WebAIM Million: The 2026 report on the accessibility of the top 1,000,000 home pages, WebAIM, Utah State University, last updated 30 March 2026.
  2. Standard. Web Content Accessibility Guidelines (WCAG) 2.2, W3C, W3C Recommendation, 12 December 2024 edition.