HSL to HEX: #6E11B0

Also known as: Tailwind purple-800

Result

hsl(275.09 82.38% 37.84%) → #6E11B0

Values are shown at full precision, so converting back gives exactly #6e11b0. 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 = 275.09°, S = 82.38%, L = 37.84%
  2. 2. C

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

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

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

    (R′, G′, B′) = (0.36462, 0.00000, 0.62345)
    R = round((0.36462 + 0.06667) × 255) = 110
    G = round((0.00000 + 0.06667) × 255) = 17
    B = round((0.62345 + 0.06667) × 255) = 176
  6. 6. RGB → HEX

    #6E11B0

All formats

HEX
#6e11b0
RGB
rgb(110 17 176)
RGB (legacy)
rgb(110, 17, 176)
HSL
hsl(275.09 82.38% 37.84%) → hsl(275 82% 38%)
HWB
hwb(275 7% 31%)
OKLCH
oklch(0.438 0.218 303.9) · oklch(43.8% 0.218 303.9)
OKLab
oklab(0.438 0.122 -0.181)
Lab (D50)
lab(30.65 56.80 -64.31)
LCH (D50)
lch(30.65 85.80 311.45)
Display P3
color(display-p3 0.3948 0.1036 0.6640)
Linear sRGB
color(srgb-linear 0.1559 0.0056 0.4342)

Gamut: sRGB and Display P3

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

CSS snippets

.element {
  color: #6e11b0;
  color: rgb(110 17 176);
  color: hsl(275 82% 38%);
  color: oklch(0.438 0.218 303.9);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.438 0.218 303.9);
}
/* arbitrary values */
class="text-[#6e11b0] bg-[oklch(0.438_0.218_303.9)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.3948 0.1036 0.6640); }
}

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

  • #7F2DC4 · oklch(0.498 0.218 303.9) · ΔL +0.06
  • #5D009C · oklch(0.378 0.218 303.9) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?