HEX naar HSL: #020617
Ook bekend als: Tailwind v3 slate-950
Resultaat
#020617 → hsl(229 84% 5%)
Waarden staan op volle precisie, dus terugrekenen geeft exact #020617. 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.0078 G = 0.0235 B = 0.0902
2. max, min, Δ
max = 0.0902 min = 0.0078 Δ = max − min = 0.0824
3. L
L = (max + min) / 2 = 0.0490 = 4.90%
4. S
S = Δ / (1 − |2L − 1|) = 0.8400 = 84.00%
5. H
max is B → H = 60° × ((R − G) / Δ + 4) = 60° × ((0.0078 − 0.0235) / 0.0824 + 4) = 228.57°
6. HSL
hsl(228.57 84.00% 4.90%)
Alle formaten
- HEX
- #020617
- RGB
- rgb(2 6 23)
- RGB (legacy)
- rgb(2, 6, 23)
- HSL
- hsl(228.57 84.00% 4.90%) → hsl(229 84% 5%)
- HWB
- hwb(229 1% 91%)
- OKLCH
- oklch(0.129 0.041 264.7) · oklch(12.9% 0.041 264.7)
- OKLab
- oklab(0.129 -0.004 -0.040)
- Lab (D50)
- lab(1.77 1.22 -8.85)
- LCH (D50)
- lch(1.77 8.93 277.85)
- Display P3
- color(display-p3 0.0106 0.0230 0.0857)
- Linear sRGB
- color(srgb-linear 0.0006 0.0018 0.0086)
Gamut: sRGB en Display P3
#020617 is een hexkleur en ligt dus binnen sRGB en daarmee binnen Display P3. Bij deze helderheid en tint haalt sRGB een chroma van 0.089 en Display P3 van 0.089; deze kleur gebruikt 46% van de beschikbare sRGB-chroma.
CSS-snippets
.element {
color: #020617;
color: rgb(2 6 23);
color: hsl(229 84% 5%);
color: oklch(0.129 0.041 264.7);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.129 0.041 264.7);
}
/* arbitrary values */
class="text-[#020617] bg-[oklch(0.129_0.041_264.7)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.0106 0.0230 0.0857); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #020617 calc(l - 0.1) c h); }Kleuren in de buurt
Dichtstbijzijnde kleuren in de Tailwind- en CSS-paletten (OKLab-afstand).
- slate-950#020618
- gray-950#030712
- zinc-950#09090B
- mauve-950#0C090C
- mist-950#090B0C
- neutral-950#0A0A0A
- stone-950#0C0A09
- olive-950#0C0C09
Lichter en donkerder, dezelfde tint en chroma
- #0A1326 · oklch(0.189 0.041 264.7) · ΔL +0.06
- #000009 · oklch(0.069 0.041 264.7) · ΔL −0.06