HEX in OKLCH: #22C55E
Auch bekannt als: Tailwind v3 green-500
Ergebnis
#22C55E → oklch(0.723 0.192 149.6)
Die Werte stehen in voller Genauigkeit, die Rückrechnung ergibt exakt #22c55e. Die gerundete Form fügst du üblicherweise in CSS ein.
Rechenweg Schritt für Schritt
Jede Zahl wird aus der Eingabe berechnet, nichts ist nachgeschlagen.
1. sRGB → linear
R: 34/255 = 0.13333 → 0.015996 (((x + 0.055) / 1.055)^2.4) G: 197/255 = 0.77255 → 0.558340 (((x + 0.055) / 1.055)^2.4) B: 94/255 = 0.36863 → 0.111932 (((x + 0.055) / 1.055)^2.4)
2. linear sRGB → LMS
l = 0.4122·R + 0.5363·G + 0.0514·B = 0.311809 m = 0.2119·R + 0.6807·G + 0.1074·B = 0.395473 s = 0.0883·R + 0.2817·G + 0.6300·B = 0.229223
3. cube root
l′ = ∛0.311809 = 0.678104 m′ = ∛0.395473 = 0.734016 s′ = ∛0.229223 = 0.612001
4. LMS′ → Oklab
L = 0.2105·l′ + 0.7936·m′ − 0.0041·s′ = 0.72275 a = 1.9780·l′ − 2.4286·m′ + 0.4506·s′ = -0.16557 b = 0.0259·l′ + 0.7828·m′ − 0.8087·s′ = 0.09722
5. Oklab → OKLCH
C = √(a² + b²) = 0.19201 H = atan2(b, a) = 149.579° L = 0.72275
6. OKLCH
oklch(0.72275 0.19201 149.579) rounded: oklch(0.723 0.192 149.6)
Alle Formate
- 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 und Display P3
#22C55E ist eine Hex-Farbe und liegt damit in sRGB und folglich in Display P3. Bei dieser Helligkeit und diesem Farbton erreicht sRGB eine Chroma von 0.201, Display P3 von 0.281; diese Farbe nutzt 95 % der verfügbaren 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); }Ähnliche Farben
Nächste Farben in den Paletten von Tailwind und CSS (OKLab-Abstand).
- green-500#00C950
- limegreen#32CD32
- emerald-500#00BC7D
- v3 emerald-500#10B981
- mediumseagreen#3CB371
- emerald-400#00D492
- green-400#05DF72
- v3 emerald-400#34D399
Heller und dunkler, gleicher Farbton und gleiche Chroma
- #41D971 · oklch(0.783 0.192 149.6) · ΔL +0.06
- #00B14B · oklch(0.663 0.192 149.6) · ΔL −0.06