RGB to HEX: #F5DEB3

Also known as: CSS wheat

Result

rgb(245 222 179) → #F5DEB3

Values are shown at full precision, so converting back gives exactly #f5deb3. 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. base 10 → base 16

    R = 245 = 15×16 + 5 → F5
    G = 222 = 13×16 + 14 → DE
    B = 179 = 11×16 + 3 → B3
  2. 2. pairs → HEX

    F5 DE B3 → #F5DEB3

All formats

HEX
#f5deb3
RGB
rgb(245 222 179)
RGB (legacy)
rgb(245, 222, 179)
HSL
hsl(39.09 76.74% 83.14%) → hsl(39 77% 83%)
HWB
hwb(39 70% 4%)
OKLCH
oklch(0.909 0.061 83.0) · oklch(90.9% 0.061 83.0)
OKLab
oklab(0.909 0.007 0.061)
Lab (D50)
lab(89.59 3.48 24.21)
LCH (D50)
lch(89.59 24.46 81.83)
Display P3
color(display-p3 0.9456 0.8738 0.7213)
Linear sRGB
color(srgb-linear 0.9131 0.7305 0.4508)

Gamut: sRGB and Display P3

#F5DEB3 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.093 and Display P3 reaches 0.115; this color uses 66% of the sRGB chroma available.

CSS snippets

.element {
  color: #f5deb3;
  color: rgb(245 222 179);
  color: hsl(39 77% 83%);
  color: oklch(0.909 0.061 83.0);
}

/* Tailwind CSS v4 */
@theme {
  --color-brand: oklch(0.909 0.061 83.0);
}
/* arbitrary values */
class="text-[#f5deb3] bg-[oklch(0.909_0.061_83.0)]"

/* wide-gamut screens */
@media (color-gamut: p3) {
  .element { color: color(display-p3 0.9456 0.8738 0.7213); }
}

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

  • #FFF2C6 · oklch(0.969 0.061 83.0) · ΔL +0.06
  • #E1CAA0 · oklch(0.849 0.061 83.0) · ΔL −0.06

Open in the studio

Other converters for this color

All converters →

Guides: What is OKLCH?