How to Fix Low Contrast Text: 5 Fixes With Real Numbers

Your audit flagged a pair at 2.5:1 and now you need a fix that does not wreck the design. Good news: most failures are fixed by moving one color a few steps, not by redesigning the page. Every number below is computed with the WCAG 2.1 formula, so you can copy the exact hex values with confidence.

Fix 1: Darken the text (the usual winner)

Light gray body text is the single most common failure. The fix is a darker gray — same look, passing ratio:

Gray on whiteRatioVerdict (normal text)
#9CA3AF2.54:1Fail
#6B72804.83:1AA pass
#4B55637.56:1AAA pass

One step (#6B7280) already clears AA; two steps (#4B5563) clears AAA and buys margin against future tweaks. Do not ship a pair that passes by 0.04 — aim for 5:1 or better.

#9CA3AF on white — 2.54:1, fails.
#4B5563 on white — 7.56:1, AAA.

Fix 2: Darken the background (for white text on brand color)

Bright brand colors make cheerful buttons and unreadable labels. Keep the hue family, darken the fill used behind text:

White on blueRatioVerdict (normal text)
#60A5FA2.54:1Fail
#3B82F63.68:1Fail (large text only)
#2563EB5.17:1AA pass

The same ladder works for amber: white on #F59E0B is 2.15:1, on #D97706 is 3.19:1 (large text only), and on #B45309 is 5.02:1 (AA). The bright version can stay for large fills and icons — reserve the dark version for text.

Fix 3: Flip it — dark text on a light tint

Sometimes the brand color simply cannot go dark enough without looking wrong. Flip the pair instead: use the brand color as text on its own pale tint.

White on #60A5FA — 2.54:1, fails.
#1E40AF on #DBEAFE — 7.15:1, AAA.

Dark blue #1E40AF on pale blue #DBEAFE scores 7.15:1 (AAA) while staying unmistakably blue. This flip is the standard fix for badges, tags, and alert banners.

Fix 4: Add a scrim over photos and gradients

White text directly on a photo fails wherever the photo is light. A translucent black overlay (scrim) darkens everything behind the text evenly:

White over photo color #7A9CC6Resulting bgRatioVerdict
No scrim#7A9CC62.84:1Fail
30% black scrim#556D8B5.32:1AA pass
50% black scrim#3D4E638.51:1AAA pass

In CSS: background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url(photo.jpg). If a scrim would ruin the photo, put the text on a solid chip instead — a dark rounded rectangle behind the text always scores exactly what the checker says it does. For gradients specifically, see the text-over-gradient guide and check the weakest point with the gradient checker.

Fix 5: Enlarge to large text — only when it truly is large

Large text (at least 18pt / about 24px, or 14pt / about 18.66px bold) only needs 3:1 at AA. That rescues some pairs legitimately:

Red #E53935 on white — 4.23:1: fails normal text, passes large text.

But this is the most abused fix in accessibility. Bold body copy at normal size is not large text, and bumping a failing paragraph to 24px just to pass is a design change, not a fix. Use this only for text that was already meant to be a headline.

What not to do

Verify your fix in 10 seconds

Enter the before and after colors — the free checker computes the exact WCAG ratio and grades it against AA and AAA.

Open the Contrast Checker

FAQ

What is the fastest way to fix low contrast text?

Darken the text one or two steps until the ratio clears 4.5:1 with margin. Gray #9CA3AF on white scores 2.54:1, but #6B7280 scores 4.83:1 (AA) and #4B5563 scores 7.56:1 (AAA).

Does making text bold fix a contrast failure?

Only if the text becomes genuinely large text: at least 18pt (about 24px), or 14pt (about 18.66px) bold, which lowers the AA bar from 4.5:1 to 3:1. Bold body copy at normal size does not change the requirement.

How do I fix white text over a photo or gradient?

Add a dark scrim or put the text on a solid chip. White on a mid-blue photo color #7A9CC6 scores 2.84:1; a 30% black scrim darkens it to #556D8B for 5.32:1 (AA), and a 50% scrim reaches #3D4E63 for 8.51:1 (AAA).

Should I aim for exactly 4.5:1?

No — aim above it with margin. A pair at 4.54:1 passes today and fails after the next designer tweaks one hex digit. 7:1 (AAA) for body text, or at least 5:1, leaves room for future edits.

Can I keep my brand color and still pass?

Often yes, by darkening the brand color for text use while keeping the bright version for large fills and icons. White on brand blue #60A5FA scores 2.54:1, but white on the darker #2563EB scores 5.17:1.