Convert RGB to OKLCH
Paste a RGB color to get its OKLCH value — and every other format — with a live swatch. All in your browser.
That doesn't look like a valid color.
- HEX
-
- RGB
-
- HSL
-
- OKLCH
-
RGB to OKLCH, explained
RGB describes a color by its red, green and blue channels, each from 0 to 255 — the form canvas drawing and image code expect.
OKLCH is a modern, perceptually-uniform space describing lightness (%), chroma and hue (°), great for accessible palettes and smooth gradients.
Worked example
rgb(245, 158, 11) converts to oklch(76.86% 0.1647 70.08). The converter above is pre-filled with this color — edit it or pick your own to see the result update live.
RGB to OKLCH reference table
| Color | RGB | OKLCH |
|---|---|---|
| Amber | rgb(245, 158, 11) | oklch(76.86% 0.1647 70.08) |
| Navy | rgb(10, 24, 40) | oklch(20.56% 0.0376 252.93) |
| Red | rgb(220, 38, 38) | oklch(57.71% 0.2152 27.33) |
| Green | rgb(22, 163, 74) | oklch(62.71% 0.1699 149.21) |
| Sky | rgb(14, 165, 233) | oklch(68.47% 0.1479 237.32) |
Common uses
OKLCH gives RGB colours a perceptually-uniform form, so equal numeric steps look like equal visual steps when building gradients and scales.
Related conversions
Need another format? The full color converter reads HEX, RGB, HSL, OKLCH and CSS named colors and shows them all at once.
Frequently asked questions
How do I convert RGB to OKLCH?
Paste your RGB value into the converter above and it shows the OKLCH equivalent — along with every other format — instantly. For example, rgb(245, 158, 11) becomes oklch(76.86% 0.1647 70.08).
What is RGB rgb(245, 158, 11) in OKLCH?
rgb(245, 158, 11) in OKLCH is oklch(76.86% 0.1647 70.08).
Is my color sent to a server?
No. Every conversion runs locally in your browser using the canvas color parser and standard color math, so nothing you enter is uploaded.