About Color Gamut Checker
Paste a color in any CSS notation, such as oklch(), lab(), color(display-p3 …) or a plain hex code, and see at once whether it lies inside sRGB, Display P3 and Rec. 2020. Wide-gamut colors look vivid on recent phones and laptops, but an ordinary screen has to show something else, and it helps to know what.
For every color the tool gives an sRGB fallback as hex and a Display P3 fallback as color(display-p3 …), with how far each one moved. Paste a whole list of design tokens, one a line, to check a palette in one go.
How it works
- Each color is converted into the RGB channels of sRGB, Display P3 and Rec. 2020. It fits a space when all three channels lie between 0 and 1, allowing only for rounding.
- With Map chroma, a color that does not fit keeps its OKLCH lightness and hue while its chroma is lowered until it fits, following the CSS Color 4 gamut-mapping method.
- With Clip channels, each out-of-range channel is simply cut to 0 or 1. That is quicker but can shift the hue, which the reported distance makes visible.
- The distance shown is the OKLab difference between the color as written and its fallback, times 100.
Questions
Which gamut should I design for?
sRGB is what every screen can show. Display P3 covers most recent phones, tablets and laptops. Rec. 2020 is a broadcast and HDR target that few screens reach in full. Use a wider color only with an sRGB fallback beside it.
How do I use the fallback in CSS?
Write the sRGB fallback first and the wide color after it, or put the wide color inside @media (color-gamut: p3). Browsers that cannot show it keep the first value.
Why do mapping and clipping give different fallbacks?
Clipping cuts each channel separately, so a vivid orange can turn more yellow. Mapping keeps the hue and lightness and gives up only saturation, which usually looks closer to what was meant.
How many colors can I check at once?
Up to 200, one a line. Lines written as name: value; are read as tokens, and a line that is not a color is marked in the table rather than stopping the check.
Everything you enter here is processed in this browser tab. Nothing is uploaded, logged or shared. How privacy works here.