HEX naar HSL: #22C55E
Ook bekend als: Tailwind v3 green-500
Resultaat
#22C55E → hsl(142 71% 45%)
Waarden staan op volle precisie, dus terugrekenen geeft exact #22c55e. 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.1333 G = 0.7725 B = 0.3686
2. max, min, Δ
max = 0.7725 min = 0.1333 Δ = max − min = 0.6392
3. L
L = (max + min) / 2 = 0.4529 = 45.29%
4. S
S = Δ / (1 − |2L − 1|) = 0.7056 = 70.56%
5. H
max is G → H = 60° × ((B − R) / Δ + 2) = 60° × ((0.3686 − 0.1333) / 0.6392 + 2) = 142.09°
6. HSL
hsl(142.09 70.56% 45.29%)
Alle formaten
- HEX
- #22c55e
- RGB
- rgb(34 197 94)
- RGB (legacy)
- rgb(34, 197, 94)
- HSL
- hsl(142.09 70.56% 45.29%) → hsl(142 71% 45%)
- HWB
- hwb(142 13% 23%)
- OKLCH
- oklch(0.723 0.192 149.6) · oklch(72.3% 0.192 149.6)
- OKLab
- oklab(0.723 -0.166 0.097)
- Lab (D50)
- lab(70.22 -57.98 39.44)
- LCH (D50)
- lch(70.22 70.12 145.78)
- Display P3
- color(display-p3 0.3692 0.7613 0.4136)
- Linear sRGB
- color(srgb-linear 0.0160 0.5583 0.1119)
Gamut: sRGB en Display P3
#22C55E is een hexkleur en ligt dus binnen sRGB en daarmee binnen Display P3. Bij deze helderheid en tint haalt sRGB een chroma van 0.201 en Display P3 van 0.281; deze kleur gebruikt 95% van de beschikbare sRGB-chroma.
CSS-snippets
.element {
color: #22c55e;
color: rgb(34 197 94);
color: hsl(142 71% 45%);
color: oklch(0.723 0.192 149.6);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.723 0.192 149.6);
}
/* arbitrary values */
class="text-[#22c55e] bg-[oklch(0.723_0.192_149.6)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.3692 0.7613 0.4136); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #22c55e calc(l - 0.1) c h); }Kleuren in de buurt
Dichtstbijzijnde kleuren in de Tailwind- en CSS-paletten (OKLab-afstand).
- green-500#00C950
- limegreen#32CD32
- emerald-500#00BC7D
- v3 emerald-500#10B981
- mediumseagreen#3CB371
- emerald-400#00D492
- green-400#05DF72
- v3 emerald-400#34D399
Lichter en donkerder, dezelfde tint en chroma
- #41D971 · oklch(0.783 0.192 149.6) · ΔL +0.06
- #00B14B · oklch(0.663 0.192 149.6) · ΔL −0.06