HEX to OKLCH: #D2B48C

Also known as: CSS tan

Result

#D2B48C → oklch(0.786 0.064 74.6)

Values are shown at full precision, so converting back gives exactly #d2b48c. 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. sRGB → linear

    R: 210/255 = 0.82353 → 0.644480  (((x + 0.055) / 1.055)^2.4)
    G: 180/255 = 0.70588 → 0.456411  (((x + 0.055) / 1.055)^2.4)
    B: 140/255 = 0.54902 → 0.262251  (((x + 0.055) / 1.055)^2.4)
  2. 2. linear sRGB → LMS

    l = 0.4122·R + 0.5363·G + 0.0514·B = 0.523948
    m = 0.2119·R + 0.6807·G + 0.1074·B = 0.475411
    s = 0.0883·R + 0.2817·G + 0.6300·B = 0.350701
  3. 3. cube root

    l′ = ∛0.523948 = 0.806175
    m′ = ∛0.475411 = 0.780470
    s′ = ∛0.350701 = 0.705200
  4. 4. LMS′ → Oklab

    L = 0.2105·l′ + 0.7936·m′ − 0.0041·s′ = 0.78619
    a = 1.9780·l′ − 2.4286·m′ + 0.4506·s′ = 0.01693
    b = 0.0259·l′ + 0.7828·m′ − 0.8087·s′ = 0.06154
  5. 5. Oklab → OKLCH

    C = √(a² + b²) = 0.06382
    H = atan2(b, a) = 74.619°
    L = 0.78619
  6. 6. OKLCH

    oklch(0.78619 0.06382 74.619)
    rounded: oklch(0.786 0.064 74.6)

All formats

HEX
#d2b48c
RGB
rgb(210 180 140)
RGB (legacy)
rgb(210, 180, 140)
HSL
hsl(34.29 43.75% 68.63%) → hsl(34 44% 69%)
HWB
hwb(34 55% 18%)
OKLCH
oklch(0.786 0.064 74.6) · oklch(78.6% 0.064 74.6)
OKLab
oklab(0.786 0.017 0.062)
Lab (D50)
lab(75.23 6.93 24.68)
LCH (D50)
lch(75.23 25.63 74.32)
Display P3
color(display-p3 0.8043 0.7102 0.5683)
Linear sRGB
color(srgb-linear 0.6445 0.4564 0.2623)

Gamut: sRGB and Display P3

#D2B48C is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.166 and Display P3 reaches 0.191; this color uses 38% of the sRGB chroma available.

CSS snippets

.element {
  color: #d2b48c;
  color: rgb(210 180 140);
  color: hsl(34 44% 69%);
  color: oklch(0.786 0.064 74.6);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.786 0.064 74.6);
}
/* arbitrary values */
class="text-[#d2b48c] bg-[oklch(0.786_0.064_74.6)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.8043 0.7102 0.5683); }
}

/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #d2b48c 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

  • #E6C79F · oklch(0.846 0.064 74.6) · ΔL +0.06
  • #BFA17A · oklch(0.726 0.064 74.6) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?