lab()

The lab() functional notation expresses a given color in the CIE L*a*b* color space. Lab represents the entire range of color that humans can see.

Syntax

lab(29.2345% 39.3825 20.0664);
lab(52.2345% 40.1645 59.9971);
lab(52.2345% 40.1645 59.9971 / .5);

Values

Functional notation: lab(L a b [/ A])

L specifies the CIE Lightness, and is a <percentage> between 0% representing black and 100% representing white.

The second argument a is the distance along the a axis in the Lab colorspace.

The third argument b is the distance along the b axis in the Lab colorspace.

A (alpha) can be a <number> between 0 and 1, or a <percentage>, where the number 1 corresponds to 100% (full opacity).

Specificatiions

Browser compatibility

Desktop Mobile
Chrome Edge Firefox Internet Explorer Opera Safari WebView Android Chrome Android Firefox for Android Opera Android Safari on IOS Samsung Internet
lab()
No
No
No
No
No
15
No
No
No
No
15
No

See also

© 2005–2021 MDN contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/CSS/color_value/lab()