OKLCH to HEX: #7C7C67

Also known as: Tailwind olive-500

Result

oklch(0.58028 0.03098 107.327) → #7C7C67

Values are shown at full precision, so converting back gives exactly #7c7c67. 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.58028 0.03098 107.327)
  2. 2. OKLCH → Oklab

    a = C·cos H = -0.00923
    b = C·sin H = 0.02957
  3. 3. Oklab → LMS′

    l′ = L + 0.3963·a + 0.2158·b = 0.583005
    m′ = L − 0.1056·a − 0.0639·b = 0.579366
    s′ = L − 0.0895·a − 1.2915·b = 0.542911
  4. 4. cube

    l = 0.583005³ = 0.198161
    m = 0.579366³ = 0.194472
    s = 0.542911³ = 0.160024
  5. 5. LMS → linear sRGB

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

    R = 0.48627 × 255 = 124.00 → 124
    G = 0.48627 × 255 = 124.00 → 124
    B = 0.40392 × 255 = 103.00 → 103
  7. 7. RGB → HEX

    #7C7C67

All formats

HEX
#7c7c67
RGB
rgb(124 124 103)
RGB (legacy)
rgb(124, 124, 103)
HSL
hsl(60.00 9.25% 44.51%) → hsl(60 9% 45%)
HWB
hwb(60 40% 51%)
OKLCH
oklch(0.580 0.031 107.3) · oklch(58.0% 0.031 107.3)
OKLab
oklab(0.580 -0.009 0.030)
Lab (D50)
lab(51.56 -2.87 11.53)
LCH (D50)
lch(51.56 11.88 103.98)
Display P3
color(display-p3 0.4863 0.4863 0.4121)
Linear sRGB
color(srgb-linear 0.2016 0.2016 0.1356)

Gamut: sRGB and Display P3

#7C7C67 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.125 and Display P3 reaches 0.145; this color uses 25% of the sRGB chroma available.

CSS snippets

.element {
  color: #7c7c67;
  color: rgb(124 124 103);
  color: hsl(60 9% 45%);
  color: oklch(0.580 0.031 107.3);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.580 0.031 107.3);
}
/* arbitrary values */
class="text-[#7c7c67] bg-[oklch(0.580_0.031_107.3)]"

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

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

  • #8E8E78 · oklch(0.640 0.031 107.3) · ΔL +0.06
  • #6B6B56 · oklch(0.520 0.031 107.3) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?