TurantToolsdev</> All tools

Dark Mode Contrast: Where Most Themes Fail

Six text colours on a dark slate background, and four rules for an accessible dark theme.

By the TurantTools Dev team · Updated October 27, 2026 · 3 min read

Dark themes have their own contrast traps. Muted greys that look elegant often fail, colours copied from the light theme turn too dark, and pure white on near-black can feel harsh for long reading.

Text colours on a #0f172a background

TextColourRatioAA normal
Pure white#ffffff17.85Pass
Soft white#e2e8f014.48Pass
Muted grey#94a3b86.96Pass
Dim grey#64748b3.75Fail
Light-mode blue link#2563eb3.45Fail
Lighter blue link#60a5fa7.02Pass

Rules that work

  1. Don't invert your palette: pick lighter tints of brand colours for dark mode links and accents.
  2. Use a soft white (around 13–15:1) for body text rather than pure white at 17:1 or more.
  3. Keep secondary text above 4.5:1; the "dim grey" look is where most dark themes fail.
  4. Define both themes as tokens and check every pair, including focus rings and borders.
Colour Contrast CheckerCheck your dark theme colours.

Sources we checked

More articles