HSL to HEX: #E6E6FA

Also known as: CSS lavender

Result

hsl(240.00 66.67% 94.12%) → #E6E6FA

Values are shown at full precision, so converting back gives exactly #e6e6fa. 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 = 240.00°, S = 66.67%, L = 94.12%
  2. 2. C

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

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

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

    (R′, G′, B′) = (0.00000, 0.00000, 0.07840)
    R = round((0.00000 + 0.90200) × 255) = 230
    G = round((0.00000 + 0.90200) × 255) = 230
    B = round((0.07840 + 0.90200) × 255) = 250
  6. 6. RGB → HEX

    #E6E6FA

All formats

HEX
#e6e6fa
RGB
rgb(230 230 250)
RGB (legacy)
rgb(230, 230, 250)
HSL
hsl(240.00 66.67% 94.12%) → hsl(240 67% 94%)
HWB
hwb(240 90% 2%)
OKLCH
oklch(0.931 0.027 285.9) · oklch(93.1% 0.027 285.9)
OKLab
oklab(0.931 0.007 -0.026)
Lab (D50)
lab(91.74 2.78 -9.72)
LCH (D50)
lch(91.74 10.11 285.93)
Display P3
color(display-p3 0.9020 0.9020 0.9737)
Linear sRGB
color(srgb-linear 0.7913 0.7913 0.9560)

Gamut: sRGB and Display P3

#E6E6FA is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.035 and Display P3 reaches 0.038; this color uses 78% of the sRGB chroma available.

CSS snippets

.element {
  color: #e6e6fa;
  color: rgb(230 230 250);
  color: hsl(240 67% 94%);
  color: oklch(0.931 0.027 285.9);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.931 0.027 285.9);
}
/* arbitrary values */
class="text-[#e6e6fa] bg-[oklch(0.931_0.027_285.9)]"

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

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

  • #FAFAFF · oklch(0.991 0.027 285.9) · ΔL +0.06
  • #D2D2E6 · oklch(0.871 0.027 285.9) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?