HSL to HEX: #FFFBEB

Also known as: Tailwind amber-50, Tailwind v3 amber-50

Result

hsl(48.00 100.00% 96.08%) → #FFFBEB

Values are shown at full precision, so converting back gives exactly #fffbeb. 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 = 48.00°, S = 100.00%, L = 96.08%
  2. 2. C

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

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

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

    (R′, G′, B′) = (0.07840, 0.06272, 0.00000)
    R = round((0.07840 + 0.92160) × 255) = 255
    G = round((0.06272 + 0.92160) × 255) = 251
    B = round((0.00000 + 0.92160) × 255) = 235
  6. 6. RGB → HEX

    #FFFBEB

All formats

HEX
#fffbeb
RGB
rgb(255 251 235)
RGB (legacy)
rgb(255, 251, 235)
HSL
hsl(48.00 100.00% 96.08%) → hsl(48 100% 96%)
HWB
hwb(48 92% 0%)
OKLCH
oklch(0.987 0.021 95.3) · oklch(98.7% 0.021 95.3)
OKLab
oklab(0.987 -0.002 0.021)
Lab (D50)
lab(98.61 -0.62 8.19)
LCH (D50)
lch(98.61 8.22 94.34)
Display P3
color(display-p3 0.9972 0.9848 0.9277)
Linear sRGB
color(srgb-linear 1.0000 0.9647 0.8308)

Gamut: sRGB and Display P3

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

CSS snippets

.element {
  color: #fffbeb;
  color: rgb(255 251 235);
  color: hsl(48 100% 96%);
  color: oklch(0.987 0.021 95.3);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.987 0.021 95.3);
}
/* arbitrary values */
class="text-[#fffbeb] bg-[oklch(0.987_0.021_95.3)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.9972 0.9848 0.9277); }
}

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

  • #FFFFEF · oklch(1.000 0.021 95.3) · ΔL +0.06
  • #EBE7D7 · oklch(0.927 0.021 95.3) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?