Lab to OKLCH Converter

Converted OKLCH Output --
100%

Wide-Gamut & Linear Formats

Modern CSS color space notations derived from this color

Contrast Analysis (WCAG 2.1)

Checks the converted color against foreground or background targets for accessibility compliance.

How to Convert CIELAB to OKLCH

Converting CIELAB (Lab) to OKLCH takes an older, Cartesian color space and upgrades it to a modern, cylindrical format built on flawless perceptual math.

The Evolution of Perceptual Color

CIELAB was the standard for perceptual color for decades. It uses an L axis for lightness, and a and b axes for color. However, it suffers from hue shifts (particularly in the blue spectrum) and is difficult to read manually.

OKLCH solves both problems. It uses the updated OKLab math to fix the hue shifts, ensuring perfect gradients and color mixing. It then formats that data as Lightness, Chroma, and Hue, making it as easy to read and manipulate as HSL, but with absolute perceptual accuracy.

The Conversion Process

To convert CIELAB to OKLCH, the color must pass through several stages:

  1. Lab to Linear RGB: The CIELAB values are converted to CIE XYZ, and then to Linear sRGB.
  2. Linear RGB to OKLab: The linear light is processed through LMS cone response matrices to generate OKLab L, a, and b coordinates.
  3. OKLab to OKLCH: Trigonometry is used to convert the a and b coordinates into Chroma (radius) and Hue (angle).

Related Tools