TXT · Text & Data tools

OKLab to HEX Converter

Active color#000000

oklab(0% 0 0)

OKLab Input
Hex Output
1Active Line0Valid Items
Go To Full Color Converter

Shareable link

Settings are written to the URL as you change them. Nothing differs from the defaults yet.

Convert OKLab color values into a hexadecimal color code your browser and CSS already understand.

Input formats

Provide colors using oklab(L a b) syntax, with lightness as a percentage from 0% to 100% and the a and b axes as small plain numbers. Each line is parsed independently in batch mode.

Hex output

The output is formatted as a 6-digit hex code in uppercase (#RRGGBB). oklab(68.04% 0.1747 0.1165) becomes #FF5733.

Out-of-gamut values

OKLab, like CIELAB, can represent colors beyond the sRGB gamut a typical screen displays. When a and b combine with the given lightness to fall outside that range, each RGB channel clamps to 0-255, which can shift the output slightly from the exact OKLab value.

Frequently Asked Questions

oklab(L a b) with L as a percentage (or a 0-1 number) and a/b as small plain numbers, such as oklab(68.04% 0.1747 0.1165). Paste one color per line for batch conversion.

No. OKLab can describe colors outside what an sRGB screen can display. Out-of-gamut results are clamped to the nearest representable RGB value.

OKLab keeps hue more consistent than older models as lightness or chroma changes, so a gradient interpolated through OKLab tends to avoid the muddy or overly saturated midpoints that RGB or HSL interpolation can produce.

Try one of our format-specific converters below

Full Color Converter tool

Explore Our Tools

Browse all tools