No Login Data Private Local Save

CIELAB to RGB Converter - Online Bring Color Back

11
0
0
0

CIELAB to RGB Converter

Convert CIE L*a*b* color values to sRGB and HEX. Visualize, copy, and explore the CIELAB color space — bring your abstract color data back to life.

L* Lightness (0–100)
Black 50 White
a* Green (−) to Red (+)
Green 0 Red
b* Blue (−) to Yellow (+)
Blue 0 Yellow
Color Preview ← pick
#808080
Out of sRGB gamut — colors clipped for display

Drag sliders or pick a color to explore

RGB Output
rgb(128, 128, 128)
HEX Code
#808080
Integer RGB
R: 128, G: 128, B: 128
Current CIELAB:
L* = 50, a* = 0, b* = 0
Preset Colors

Click a swatch to load its CIELAB values

Frequently Asked Questions

Learn more about CIELAB color space and conversion

CIELAB (also known as CIE L*a*b* or simply Lab) is a color space defined by the International Commission on Illumination (CIE) in 1976. It was designed to be perceptually uniform, meaning that equal changes in L*a*b* values correspond to roughly equal perceived changes in color. Unlike device-dependent color spaces like RGB or CMYK, CIELAB is device-independent and encompasses all colors visible to the human eye. The three axes are: L* for lightness (0 = black, 100 = white), a* for the green–red axis (negative = green, positive = red), and b* for the blue–yellow axis (negative = blue, positive = yellow).

L* (Lightness): Ranges from 0 to 100, where 0 represents absolute black, 100 represents perfect white (diffuse white reference), and 50 represents middle gray.

a* (Green–Red axis): Negative values indicate green; positive values indicate red. Typical ranges span approximately −128 to +127, though values can extend further in theory.

b* (Blue–Yellow axis): Negative values indicate blue; positive values indicate yellow. Like a*, the typical range is roughly −128 to +127.

When a* = 0 and b* = 0, the color is a neutral gray whose lightness is determined solely by L*.

The conversion involves three major steps:

Step 1 — CIELAB to CIE XYZ: Using the D65 reference white point (Xref = 95.047, Yref = 100, Zref = 108.883), the L*a*b* values are reverse-transformed to the XYZ tristimulus space using the CIE standard formulas involving a cube-root nonlinearity.

Step 2 — XYZ to Linear RGB: The XYZ values (normalized to Y = 1) are multiplied by the sRGB transformation matrix to obtain linear RGB values.

Step 3 — Linear RGB to sRGB: Gamma correction (≈2.4 gamma with a linear segment near black) is applied to produce the final sRGB values, which are then scaled to 0–255 and clipped if necessary.

The CIELAB color space is larger than the sRGB gamut. CIELAB can represent all colors visible to the human eye, while sRGB covers only a subset (roughly 35% of visible colors). When a CIELAB color falls outside the sRGB gamut, one or more of the calculated RGB components will be less than 0 or greater than 255. This tool clips out-of-range values to the nearest valid boundary (0 or 255) and displays a warning. The preview shows the closest displayable approximation. For critical color work, consider using wide-gamut color spaces like Display P3 or Adobe RGB.

D65 is the CIE standard illuminant representing average daylight with a correlated color temperature of approximately 6500K. It is the standard reference white point used in sRGB and most modern display technologies. In CIELAB conversion, D65 defines the tristimulus values Xref = 95.047, Yref = 100.000, and Zref = 108.883. These values serve as the "white anchor" — a CIELAB color with L* = 100, a* = 0, b* = 0 corresponds exactly to this D65 white under the conversion.

Here are approximate CIELAB (D65) values for some common sRGB colors:

Pure Red: L* ≈ 53, a* ≈ +80, b* ≈ +67
Pure Green: L* ≈ 88, a* ≈ −86, b* ≈ +83
Pure Blue: L* ≈ 32, a* ≈ +79, b* ≈ −108
Pure Yellow: L* ≈ 98, a* ≈ −16, b* ≈ +93
50% Gray: L* ≈ 54, a* ≈ 0, b* ≈ 0
White: L* = 100, a* = 0, b* = 0
Black: L* = 0, a* = 0, b* = 0

Use the preset swatches above to quickly explore these common reference points.

Both CIELAB (CIE 1976 L*a*b*) and Hunter Lab (developed by Richard S. Hunter in 1948) are opponent-type color spaces, but they use different mathematical transformations. Hunter Lab uses square-root functions, while CIELAB uses cube-root functions. CIELAB provides better perceptual uniformity, especially in the blue region of the color space. Today, CIELAB is the internationally recognized standard (ISO/CIE 11664-4) and is far more commonly used in modern color science, digital imaging, and industrial color management. When someone says "Lab color space" today, they almost always mean CIELAB.

Converting CIELAB to RGB is essential in many fields:

• Digital Imaging & Photography: RAW photo processors use CIELAB internally for color adjustments before exporting to RGB formats.
• Computer Vision & AI: Many color-based algorithms work in CIELAB for its perceptual uniformity, then convert results to RGB for display.
• Textile & Paint Industries: Spectrophotometers often output CIELAB values that need conversion for digital representation.
• Scientific Visualization: Researchers use CIELAB to represent color differences accurately, then convert to RGB for publication figures.
• Color Quality Control: ΔE (color difference) calculations use CIELAB, and results often need RGB visualization for reports.

This converter implements the standard CIE and IEC formulas used in the sRGB specification (IEC 61966-2-1:1999). It uses double-precision floating-point arithmetic for the intermediate calculations and applies the exact sRGB transfer function (including the linear toe-slope near black). The D65 reference white point and the standard sRGB transformation matrix are used as specified. For colors inside the sRGB gamut, the conversion is mathematically exact. For out-of-gamut colors, values are clipped to the nearest valid boundary, and a warning is displayed. The tool is suitable for professional and educational use.

This converter targets the standard sRGB color space with the D65 reference white point. It is not designed for wide-gamut spaces like Display P3, Adobe RGB, or Rec.2020, nor for HDR (High Dynamic Range) formats. CIELAB values that represent colors outside the sRGB gamut will be clipped. If you need conversion to wide-gamut RGB spaces, you would need a different transformation matrix and potentially a different reference white point. However, the CIELAB portion of the calculation (the color science) remains the same — only the XYZ-to-RGB matrix would change.