HEX naar HSL: #4D0218
Ook bekend als: Tailwind rose-950
Resultaat
#4D0218 → hsl(342 95% 15%)
Waarden staan op volle precisie, dus terugrekenen geeft exact #4d0218. De afgeronde vorm plak je gewoonlijk in CSS.
Stap-voor-stap berekening
Elk getal wordt uit de invoer berekend, er wordt niets opgezocht.
1. RGB ÷ 255
R = 0.3020 G = 0.0078 B = 0.0941
2. max, min, Δ
max = 0.3020 min = 0.0078 Δ = max − min = 0.2941
3. L
L = (max + min) / 2 = 0.1549 = 15.49%
4. S
S = Δ / (1 − |2L − 1|) = 0.9494 = 94.94%
5. H
max is R → H = 60° × (((G − B) / Δ) mod 6) = 60° × (((0.0078 − 0.0941) / 0.2941) mod 6) = 342.40°
6. HSL
hsl(342.40 94.94% 15.49%)
Alle formaten
- HEX
- #4d0218
- RGB
- rgb(77 2 24)
- RGB (legacy)
- rgb(77, 2, 24)
- HSL
- hsl(342.40 94.94% 15.49%) → hsl(342 95% 15%)
- HWB
- hwb(342 1% 70%)
- OKLCH
- oklch(0.270 0.105 12.3) · oklch(27.0% 0.105 12.3)
- OKLab
- oklab(0.270 0.103 0.022)
- Lab (D50)
- lab(14.12 33.98 9.97)
- LCH (D50)
- lch(14.12 35.42 16.36)
- Display P3
- color(display-p3 0.2743 0.0394 0.0974)
- Linear sRGB
- color(srgb-linear 0.0742 0.0006 0.0091)
Gamut: sRGB en Display P3
#4D0218 is een hexkleur en ligt dus binnen sRGB en daarmee binnen Display P3. Bij deze helderheid en tint haalt sRGB een chroma van 0.108 en Display P3 van 0.122; deze kleur gebruikt 97% van de beschikbare sRGB-chroma.
CSS-snippets
.element {
color: #4d0218;
color: rgb(77 2 24);
color: hsl(342 95% 15%);
color: oklch(0.270 0.105 12.3);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.270 0.105 12.3);
}
/* arbitrary values */
class="text-[#4d0218] bg-[oklch(0.270_0.105_12.3)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.2743 0.0394 0.0974); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #4d0218 calc(l - 0.1) c h); }Kleuren in de buurt
Dichtstbijzijnde kleuren in de Tailwind- en CSS-paletten (OKLab-afstand).
- v3 rose-950#4C0519
- v3 pink-950#500724
- pink-950#510424
- red-950#460809
- v3 red-950#450A0A
- orange-950#441306
- v3 orange-950#431407
- amber-950#461901
Lichter en donkerder, dezelfde tint en chroma
- #5F1626 · oklch(0.330 0.105 12.3) · ΔL +0.06
- #3B000A · oklch(0.210 0.105 12.3) · ΔL −0.06