HSL to HEX: #831843
Also known as: Tailwind v3 pink-900
Result
hsl(335.89 69.03% 30.39%) → #831843
Values are shown at full precision, so converting back gives exactly #831843. 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. input
H = 335.89°, S = 69.03%, L = 30.39%
2. C
C = (1 − |2L − 1|) × S = 0.41956
3. X
X = C × (1 − |(H / 60°) mod 2 − 1|) = 0.16859 (H / 60° = 5.5982, sector 5)
4. m
m = L − C / 2 = 0.09412
5. (R′, G′, B′) + m
(R′, G′, B′) = (0.41956, 0.00000, 0.16859) R = round((0.41956 + 0.09412) × 255) = 131 G = round((0.00000 + 0.09412) × 255) = 24 B = round((0.16859 + 0.09412) × 255) = 67
6. RGB → HEX
#831843
All formats
- HEX
- #831843
- RGB
- rgb(131 24 67)
- RGB (legacy)
- rgb(131, 24, 67)
- HSL
- hsl(335.89 69.03% 30.39%) → hsl(336 69% 30%)
- HWB
- hwb(336 9% 49%)
- OKLCH
- oklch(0.408 0.144 2.4) · oklch(40.8% 0.144 2.4)
- OKLab
- oklab(0.408 0.144 0.006)
- Lab (D50)
- lab(29.53 46.64 3.14)
- LCH (D50)
- lch(29.53 46.75 3.85)
- Display P3
- color(display-p3 0.4711 0.1351 0.2616)
- Linear sRGB
- color(srgb-linear 0.2270 0.0091 0.0561)
Gamut: sRGB and Display P3
#831843 is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.165 and Display P3 reaches 0.185; this color uses 88% of the sRGB chroma available.
CSS snippets
.element {
color: #831843;
color: rgb(131 24 67);
color: hsl(336 69% 30%);
color: oklch(0.408 0.144 2.4);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.408 0.144 2.4);
}
/* arbitrary values */
class="text-[#831843] bg-[oklch(0.408_0.144_2.4)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.4711 0.1351 0.2616); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #831843 calc(l - 0.1) c h); }Nearby colors
Closest colors in the Tailwind and CSS named palettes (OKLab distance).
- pink-900#861043
- v3 rose-900#881337
- rose-900#8B0836
- v3 pink-800#9D174D
- v3 red-900#7F1D1D
- red-900#82181A
- v3 rose-800#9F1239
- pink-800#A3004C
Lighter and darker, same hue and chroma
- #972D53 · oklch(0.468 0.144 2.4) · ΔL +0.06
- #6F0033 · oklch(0.348 0.144 2.4) · ΔL −0.06
Open in the studio
Other converters for this color
Guides: What is OKLCH?