HEX to HSL: #DAA520

Also known as: CSS goldenrod

Result

#DAA520 → hsl(43 74% 49%)

Values are shown at full precision, so converting back gives exactly #daa520. 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. RGB ÷ 255

    R = 0.8549
    G = 0.6471
    B = 0.1255
  2. 2. max, min, Δ

    max = 0.8549
    min = 0.1255
    Δ = max − min = 0.7294
  3. 3. L

    L = (max + min) / 2 = 0.4902 = 49.02%
  4. 4. S

    S = Δ / (1 − |2L − 1|) = 0.7440 = 74.40%
  5. 5. H

    max is R → H = 60° × (((G − B) / Δ) mod 6) = 60° × (((0.6471 − 0.1255) / 0.7294) mod 6) = 42.90°
  6. 6. HSL

    hsl(42.90 74.40% 49.02%)

All formats

HEX
#daa520
RGB
rgb(218 165 32)
RGB (legacy)
rgb(218, 165, 32)
HSL
hsl(42.90 74.40% 49.02%) → hsl(43 74% 49%)
HWB
hwb(43 13% 15%)
OKLCH
oklch(0.752 0.147 84.0) · oklch(75.2% 0.147 84.0)
OKLab
oklab(0.752 0.015 0.146)
Lab (D50)
lab(71.32 12.21 68.68)
LCH (D50)
lch(71.32 69.76 79.92)
Display P3
color(display-p3 0.8229 0.6554 0.2537)
Linear sRGB
color(srgb-linear 0.7011 0.3763 0.0144)

Gamut: sRGB and Display P3

#DAA520 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.154 and Display P3 reaches 0.178; this color uses 95% of the sRGB chroma available.

CSS snippets

.element {
  color: #daa520;
  color: rgb(218 165 32);
  color: hsl(43 74% 49%);
  color: oklch(0.752 0.147 84.0);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.752 0.147 84.0);
}
/* arbitrary values */
class="text-[#daa520] bg-[oklch(0.752_0.147_84.0)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.8229 0.6554 0.2537); }
}

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

  • #EEB83D · oklch(0.812 0.147 84.0) · ΔL +0.06
  • #C69200 · oklch(0.692 0.147 84.0) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?