HSL to HEX: #C10007

Also known as: Tailwind red-700

Result

hsl(357.82 100.00% 37.84%) → #C10007

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

    H = 357.82°, S = 100.00%, L = 37.84%
  2. 2. C

    C = (1 − |2L − 1|) × S = 0.75680
  3. 3. X

    X = C × (1 − |(H / 60°) mod 2 − 1|) = 0.02750   (H / 60° = 5.9637, sector 5)
  4. 4. m

    m = L − C / 2 = 0.00000
  5. 5. (R′, G′, B′) + m

    (R′, G′, B′) = (0.75680, 0.00000, 0.02750)
    R = round((0.75680 + 0.00000) × 255) = 193
    G = round((0.00000 + 0.00000) × 255) = 0
    B = round((0.02750 + 0.00000) × 255) = 7
  6. 6. RGB → HEX

    #C10007

All formats

HEX
#c10007
RGB
rgb(193 0 7)
RGB (legacy)
rgb(193, 0, 7)
HSL
hsl(357.82 100.00% 37.84%) → hsl(358 100% 38%)
HWB
hwb(358 0% 24%)
OKLCH
oklch(0.509 0.209 28.5) · oklch(50.9% 0.209 28.5)
OKLab
oklab(0.509 0.183 0.100)
Lab (D50)
lab(41.02 65.57 54.05)
LCH (D50)
lch(41.02 84.98 39.50)
Display P3
color(display-p3 0.6934 0.1415 0.1064)
Linear sRGB
color(srgb-linear 0.5333 0.0000 0.0021)

Gamut: sRGB and Display P3

#C10007 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.209 and Display P3 reaches 0.235; this color uses 100% of the sRGB chroma available.

CSS snippets

.element {
  color: #c10007;
  color: rgb(193 0 7);
  color: hsl(358 100% 38%);
  color: oklch(0.509 0.209 28.5);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.509 0.209 28.5);
}
/* arbitrary values */
class="text-[#c10007] bg-[oklch(0.509_0.209_28.5)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.6934 0.1415 0.1064); }
}

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

  • #D72A22 · oklch(0.569 0.209 28.5) · ΔL +0.06
  • #AB0000 · oklch(0.449 0.209 28.5) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?