What Is a Color Converter?
A color converter translates color values between different notation systems — HEX, RGB, HSL, HSB, and more. Designers work in HSB (Figma, Photoshop), developers write HEX and RGB (CSS), and print workflows use CMYK. This tool bridges those worlds with instant, accurate conversion.
When to Use Each Format
HEX — compact CSS notation, ideal for stylesheets and design tokens. RGB — matches how screens physically display color, best for programmatic manipulation. HSL — native CSS format that's intuitive for adjusting lightness and saturation without changing hue. HSB/HSV — what Figma and Photoshop use internally, best for design tool workflows.
How to Use This Color Converter
- Enter a colour — Paste a 6-digit hex code, an rgb()/rgba() value or an hsl()/hsla() value (comma-separated, whole numbers), or use the colour picker.
- See all conversions instantly — The tool converts your input to HEX, RGB, RGBA, HSL, HSLA, HSB/HSV, and CMYK simultaneously.
- Fine-tune with the sliders — Move the R, G and B sliders and every format updates together.
- Copy any format — Click the copy button next to any format to grab that specific color representation.
Worked example: what it accepts, and what rounding costs
On October 13, 2026 we typed #FF3366 written many ways (plus a colour name, an out-of-gamut OKLCH colour and a nonsense word) into the tool in Chromium, and compared the HSL it shows with the colour it came from on 6096 colours (a 16-step grid on each channel plus 2,000 random). The parser is now culori 4.0.2, self-hosted, which reads every CSS Color 4 syntax; CMYK has its own reader.
| You paste | Old tool | Tool now |
|---|---|---|
| #FF3366, ff3366 | Converted | Converted |
| rgb(255, 51, 102), rgba(255,51,102,0.5), hsl(345, 100%, 60%) | Converted (alpha dropped silently) | Converted; a note says the alpha is not kept |
| #F36, #FF336680 (3- and 8-digit hex) | Ignored | Converted |
| rgb(255 51 102), hsl(345 100% 60%) (space syntax) | Ignored | Converted |
| rgb(100% 20% 40%), hsl(345deg …), hsl(0.9583turn …) | Ignored | Converted |
| rebeccapurple, hwb(345 20% 0%) | Ignored | Converted |
| cmyk(0%, 80%, 60%, 0%), cmyk(0 0.8 0.6 0) | Ignored | Converted, with a note that it is the simple formula |
| oklch(0.6 0.4 30) (outside sRGB) | Ignored | #F70000, mapped into sRGB (same as coloraide's CSS method) with a note |
| banana | Nothing happened, no message | "Couldn't read…" message with examples |
- Input formats. Any CSS colour (hex with 3, 4, 6 or 8 digits, rgb(), hsl() and hwb() with spaces or commas, percentages and angle units, the 148 colour names, lab(), lch(), oklab(), oklch() and color()) plus cmyk(). Alpha is read but not kept, and colours outside sRGB are mapped into it; both get a note. Anything unreadable shows a message instead of being ignored.
- The HSL is shown to one decimal, which is lossless here. With whole numbers, converting the HSL back gave a different hex for 5202 of 6096 colours; with one decimal all 6096 came back to the same hex. CSS accepts decimals such as hsl(344.6, 100%, 60%).
- RGBA is always alpha 1. The tool has no alpha control; edit the last number by hand.
- CMYK is the simple formula, not a print conversion. K = 1 − max(R, G, B), and C, M, Y follow from it, with no ICC profile, ink limit or paper. #FF3366 comes out 0/80/60/0, but a print shop's profile (for example coated FOGRA39) will give different numbers, and bright screen colours like this one are outside what CMYK ink can print. Use the CMYK row as a starting point only.
- Tints and shades mix with white and black in RGB. The nine steps are 10% to 90% mixes, which drift in hue and do not look evenly spaced; for a perceptually even scale use OKLCH (the OKLCH Color Picker or Color Shade Generator).
- Editing: change the colour with the picker or the R, G and B sliders; the HSL, HSB and CMYK values are display only.
Sources
Checked on .
- W3C CSS Color Module Level 4: rgb(), hsl(), hex notations and the HSL-to-RGB algorithm
- MDN: <color> value (legacy comma syntax vs space-separated syntax)
- W3C CSS Color Level 4: gamut mapping (binary search in OKLCH with deltaEOK)
- culori 4.0.2: parse() and the supported CSS colour syntaxes (MIT)
- coloraide documentation: gamut mapping methods (cross-check of the OKLCH result)
Related tools
- For authoring colors directly in perceptually uniform space rather than converting after the fact, see the OKLCH Color Picker.
- For modern CSS Color Module Level 4 spaces (OKLCH, OKLAB, LAB, LCH, HWB, Display P3) the Color Space Converter handles every representation at once.
Frequently Asked Questions
📖 Learn More
Related Article HTML Color Codes Explained →Built by Derek Giordano · Part of Ultimate Design Tools