OKLCH to HEX: #1D1D16

Also known as: Tailwind olive-900

Result

oklch(0.22823 0.01302 107.388) → #1D1D16

Values are shown at full precision, so converting back gives exactly #1d1d16. The rounded form is what you normally paste into CSS.

Step-by-step math

Every number below is computed from the input, nothing is looked up.

  1. 1. input

    oklch(0.22823 0.01302 107.388)
  2. 2. OKLCH → Oklab

    a = C·cos H = -0.00389
    b = C·sin H = 0.01243
  3. 3. Oklab → LMS′

    l′ = L + 0.3963·a + 0.2158·b = 0.229369
    m′ = L − 0.1056·a − 0.0639·b = 0.227847
    s′ = L − 0.0895·a − 1.2915·b = 0.212531
  4. 4. cube

    l = 0.229369³ = 0.012067
    m = 0.227847³ = 0.011829
    s = 0.212531³ = 0.009600
  5. 5. LMS → linear sRGB

    R = 4.0767·l − 3.3077·m + 0.2310·s = 0.012287
    G = −1.2684·l + 2.6098·m − 0.3413·s = 0.012287
    B = −0.0042·l − 0.7034·m + 1.7076·s = 0.008022
  6. 6. linear → sRGB, × 255

    R = 0.11373 × 255 = 29.00 → 29
    G = 0.11373 × 255 = 29.00 → 29
    B = 0.08627 × 255 = 22.00 → 22
  7. 7. RGB → HEX

    #1D1D16

All formats

HEX
#1d1d16
RGB
rgb(29 29 22)
RGB (legacy)
rgb(29, 29, 22)
HSL
hsl(60.00 13.73% 10.00%) → hsl(60 14% 10%)
HWB
hwb(60 9% 89%)
OKLCH
oklch(0.228 0.013 107.4) · oklch(22.8% 0.013 107.4)
OKLab
oklab(0.228 -0.004 0.012)
Lab (D50)
lab(10.58 -1.20 4.85)
LCH (D50)
lch(10.58 5.00 103.90)
Display P3
color(display-p3 0.1137 0.1137 0.0890)
Linear sRGB
color(srgb-linear 0.0123 0.0123 0.0080)

Gamut: sRGB and Display P3

#1D1D16 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.049 and Display P3 reaches 0.057; this color uses 27% of the sRGB chroma available.

CSS snippets

.element {
  color: #1d1d16;
  color: rgb(29 29 22);
  color: hsl(60 14% 10%);
  color: oklch(0.228 0.013 107.4);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.228 0.013 107.4);
}
/* arbitrary values */
class="text-[#1d1d16] bg-[oklch(0.228_0.013_107.4)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.1137 0.1137 0.0890); }
}

/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #1d1d16 calc(l - 0.1) c h); }

Nearby colors

Closest colors in the Tailwind and CSS named palettes (OKLab distance).

Lighter and darker, same hue and chroma

  • #2B2B24 · oklch(0.288 0.013 107.4) · ΔL +0.06
  • #100F09 · oklch(0.168 0.013 107.4) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?