HEX in OKLCH: #F08080
Auch bekannt als: CSS lightcoral
Ergebnis
#F08080 → oklch(0.725 0.138 21.0)
Die Werte stehen in voller Genauigkeit, die Rückrechnung ergibt exakt #f08080. 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: 240/255 = 0.94118 → 0.871367 (((x + 0.055) / 1.055)^2.4) G: 128/255 = 0.50196 → 0.215861 (((x + 0.055) / 1.055)^2.4) B: 128/255 = 0.50196 → 0.215861 (((x + 0.055) / 1.055)^2.4)
2. linear sRGB → LMS
l = 0.4122·R + 0.5363·G + 0.0514·B = 0.486074 m = 0.2119·R + 0.6807·G + 0.1074·B = 0.354765 s = 0.0883·R + 0.2817·G + 0.6300·B = 0.273743
3. cube root
l′ = ∛0.486074 = 0.786263 m′ = ∛0.354765 = 0.707913 s′ = ∛0.273743 = 0.649304
4. LMS′ → Oklab
L = 0.2105·l′ + 0.7936·m′ − 0.0041·s′ = 0.72464 a = 1.9780·l′ − 2.4286·m′ + 0.4506·s′ = 0.12857 b = 0.0259·l′ + 0.7828·m′ − 0.8087·s′ = 0.04943
5. Oklab → OKLCH
C = √(a² + b²) = 0.13774 H = atan2(b, a) = 21.029° L = 0.72464
6. OKLCH
oklch(0.72464 0.13774 21.029) rounded: oklch(0.725 0.138 21.0)
Alle Formate
- HEX
- #f08080
- RGB
- rgb(240 128 128)
- RGB (legacy)
- rgb(240, 128, 128)
- HSL
- hsl(0.00 78.87% 72.16%) → hsl(0 79% 72%)
- HWB
- hwb(0 50% 6%)
- OKLCH
- oklch(0.725 0.138 21.0) · oklch(72.5% 0.138 21.0)
- OKLab
- oklab(0.725 0.129 0.049)
- Lab (D50)
- lab(66.65 43.82 20.51)
- LCH (D50)
- lch(66.65 48.39 25.08)
- Display P3
- color(display-p3 0.8834 0.5247 0.5138)
- Linear sRGB
- color(srgb-linear 0.8714 0.2159 0.2159)
Gamut: sRGB und Display P3
#F08080 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.171, Display P3 von 0.218; diese Farbe nutzt 81 % der verfügbaren sRGB-Chroma.
CSS-Snippets
.element {
color: #f08080;
color: rgb(240 128 128);
color: hsl(0 79% 72%);
color: oklch(0.725 0.138 21.0);
}
/* Tailwind CSS v4 */
@theme {
--color-brand: oklch(0.725 0.138 21.0);
}
/* arbitrary values */
class="text-[#f08080] bg-[oklch(0.725_0.138_21.0)]"
/* wide-gamut screens */
@media (color-gamut: p3) {
.element { color: color(display-p3 0.8834 0.5247 0.5138); }
}
/* relative color syntax: 10% darker */
.element-dark { color: oklch(from #f08080 calc(l - 0.1) c h); }Ähnliche Farben
Nächste Farben in den Paletten von Tailwind und CSS (OKLab-Abstand).
- salmon#FA8072
- v3 red-400#F87171
- v3 rose-400#FB7185
- darksalmon#E9967A
- red-400#FF6467
- coral#FF7F50
- rose-400#FF637E
- palevioletred#DB7093
Heller und dunkler, gleicher Farbton und gleiche Chroma
- #FF9392 · oklch(0.785 0.138 21.0) · ΔL +0.06
- #DB6D6E · oklch(0.665 0.138 21.0) · ΔL −0.06