HSL to HEX: #0C090C
Also known as: Tailwind mauve-950
Result
hsl(300.00 14.29% 4.12%) → #0C090C
Values are shown at full precision, so converting back gives exactly #0c090c. 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 = 300.00°, S = 14.29%, L = 4.12%
2. C
C = (1 − |2L − 1|) × S = 0.01177
3. X
X = C × (1 − |(H / 60°) mod 2 − 1|) = 0.01177 (H / 60° = 5.0000, sector 5)
4. m
m = L − C / 2 = 0.03531
5. (R′, G′, B′) + m
(R′, G′, B′) = (0.01177, 0.00000, 0.01177) R = round((0.01177 + 0.03531) × 255) = 12 G = round((0.00000 + 0.03531) × 255) = 9 B = round((0.01177 + 0.03531) × 255) = 12
6. RGB → HEX
#0C090C
All formats
- HEX
- #0c090c
- RGB
- rgb(12 9 12)
- RGB (legacy)
- rgb(12, 9, 12)
- HSL
- hsl(300.00 14.29% 4.12%) → hsl(300 14% 4%)
- HWB
- hwb(300 4% 95%)
- OKLCH
- oklch(0.145 0.008 326.0) · oklch(14.5% 0.008 326.0)
- OKLab
- oklab(0.145 0.007 -0.005)
- Lab (D50)
- lab(2.71 1.17 -0.88)
- LCH (D50)
- lch(2.71 1.46 322.95)
- Display P3
- color(display-p3 0.0451 0.0357 0.0463)
- Linear sRGB
- color(srgb-linear 0.0037 0.0027 0.0037)
Gamut: sRGB and Display P3
#0C090C is a hex color, so it sits inside sRGB and therefore inside Display P3. At this lightness and hue, sRGB reaches chroma 0.068 and Display P3 reaches 0.074; this color uses 12% of the sRGB chroma available.
CSS snippets
.element {
color: #0c090c;
color: rgb(12 9 12);
color: hsl(300 14% 4%);
color: oklch(0.145 0.008 326.0);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.145 0.008 326.0);
}
/* arbitrary values */
class="text-[#0c090c] bg-[oklch(0.145_0.008_326.0)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.0451 0.0357 0.0463); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #0c090c calc(l - 0.1) c h); }Nearby colors
Closest colors in the Tailwind and CSS named palettes (OKLab distance).
- zinc-950#09090B
- neutral-950#0A0A0A
- stone-950#0C0A09
- mist-950#090B0C
- olive-950#0C0C09
- gray-950#030712
- v3 slate-950#020617
- slate-950#020618
Lighter and darker, same hue and chroma
- #191619 · oklch(0.205 0.008 326.0) · ΔL +0.06
- #030203 · oklch(0.085 0.008 326.0) · ΔL −0.06
Open in the studio
Other converters for this color
Guides: What is OKLCH?