OKLCH Studio · Tailwind v3 → v4

Tailwind fuchsia-400: v3 #e879f9 vs v4 oklch(0.740 0.238 322.2)

ChangedIn v4, fuchsia-400 is darker and more saturated than in v3 (ΔL -0.008, ΔC +0.031, ΔH 0.0°).

The v4 value is outside the sRGB gamut, so #ED6AFF is a clipped sRGB approximation; wide-gamut displays can show it more vivid.

Tailwind v3#e879f9
Tailwind v4oklch(0.740 0.238 322.2)
Tailwind fuchsia-400 values in v3 and v4
v3 hex#e879f9
v3 as oklch()oklch(0.748 0.207 322.2)
v4 oklch()oklch(0.740 0.238 322.2)
v4 hex#ED6AFF
ΔE-OK (×100)3.20
ΔL (v4 − v3)-0.008
ΔC (v4 − v3)0.031
ΔH (v4 − v3)0°

Copy code

Tailwind v3 usage

color: #e879f9;

// tailwind.config.js (v3)
colors.fuchsia[400] // #e879f9

Tailwind v4 @theme token

@theme {
  --color-fuchsia-400: oklch(0.740 0.238 322.2);
}

.example {
  color: var(--color-fuchsia-400);
}

Keep the v3 colour in v4

@theme {
  --color-fuchsia-400: #e879f9;
}

Related

← All Tailwind v3 to v4 colors