Skip to main content

Unified Color Space Converter

Paste one color in any format — HEX, RGB, HSL, HSV/HSB, CMYK, LAB, LCH, XYZ, Oklab, or a CSS name — and instantly see its equivalent in every other color space, with a live swatch and the nearest named color.

Input

Auto-detects HEX, RGB(A), HSL(A), HSV/HSB, CMYK, LAB, LCH, Oklab, XYZ, or CSS named colors.

Output

Your color will appear here.

Swatch HTML
 
Was this helpful?

Guides

Paste a color in almost any format and see it instantly translated into every other color space at once — no more juggling ten single-purpose converters.

Supported formats

Input (auto-detected): HEX (#rrggbb or #rgb), rgb()/rgba(), hsl()/hsla(), hsv()/hsb(), cmyk(), lab(), lch(), xyz(), oklab(), and CSS named colors (cornflowerblue, blueviolet, …).

Output: HEX, RGB, HSL, HSV, CMYK, LAB, LCH, XYZ, Oklab, and the nearest CSS named color (with its ΔE distance, so you know how close the match really is) — plus a live color swatch.

How the conversions work

Everything routes through sRGB as the common pivot: HSL/HSV/CMYK convert directly to and from RGB; LAB/LCH/XYZ go through the standard sRGB → linear-RGB → CIE XYZ (D65 white point) → CIE LAB pipeline (and LCH is LAB in polar form); Oklab uses the Björn Ottosson matrices for a perceptually-uniform alternative to LAB. The named-color match is the closest CIE76 ΔE distance across the full CSS named-color list.

How to use it

  1. Paste a color value in any supported format — the tool detects which one automatically.
  2. Read off the equivalent value in every other space.
  3. Copy the swatch HTML to embed a quick color reference, or copy any individual value.

Everything runs client-side; your color values are never sent anywhere.

Why don't my LAB/XYZ numbers match another tool exactly?

Small differences (usually in the second decimal place) are normal — they come from which reference white point and RGB primaries a tool assumes. This converter uses the sRGB/D65 standard, the most common convention on the web.

colorconverterrgbhexhslhsvcmyklablchxyzoklabcss

More ways to use this tool

REST API

curl -X POST https://api.iotools.cloud/v1/tool/unified-color-space-converter \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "colorInput": "#FF0000"
  }'

Swap in your own key from your account. The tool's fields are the body — no wrapper.

Ask an AI agent

Use the IOTools `unified-color-space-converter` tool (Unified Color Space Converter) on this input:

YOUR_INPUT_HERE

Paste this at any agent connected to the IOTools MCP server, then add your input.

Embed widget

<iframe
  src="https://iotools.cloud/embed/unified-color-space-converter/"
  width="100%" height="520" frameborder="0" scrolling="no" loading="lazy"
  title="Unified Color Space Converter — iotools.cloud"
  sandbox="allow-scripts allow-forms allow-same-origin allow-downloads allow-popups allow-popups-to-escape-sandbox"
  allow="clipboard-write"
  style="width:100%;border:1px solid #e5e7eb;border-radius:12px;overflow:hidden"></iframe>
<script src="https://iotools.cloud/embed.js" async></script>

Drop this into your own page — free, no key required, just a link back.

Cost per callFrom 5 credits

Also available with

Love the tools? Lose the ads.

One payment clears every ad from your account, for good. No subscription, no tracking.