Can you convert a HEX color to CMYK?
Yes, numerically. This tool reads a HEX code, splits it into red, green and blue, and works out the cyan, magenta, yellow and black ink percentages that would reproduce it under ideal conditions. #1E90FF gives cmyk(88.2%, 43.5%, 0%, 0%). What a real press prints from those numbers depends on its inks, paper and color profile.
The typical reason to run this conversion: your brand colors were picked on screen and live in a CSS file, and now someone needs them for business cards, a banner or packaging. The designer or printer asks for CMYK, and you have #1E90FF.
The formula behind it
The tool uses the same arithmetic the W3C describes as the "naive" conversion in CSS Color Module Level 5. With red, green and blue scaled to 0–1:
| Ink | Formula |
|---|---|
| Black (K) | 1 − max(R, G, B) |
| Cyan (C) | (1 − R − K) / (1 − K) |
| Magenta (M) | (1 − G − K) / (1 − K) |
| Yellow (Y) | (1 − B − K) / (1 − K) |
Each result is multiplied by 100 and rounded to one decimal place. When K is 100% (pure black) the other three are set to 0 instead of dividing by zero.
For #1E90FF: R = 30/255 = 0.118, G = 144/255 = 0.565, B = 1. The brightest channel is blue at 1, so K = 0. Cyan is 1 − 0.118 = 0.882, magenta 1 − 0.565 = 0.435, yellow 0. That's 88.2 / 43.5 / 0 / 0.
The spec is blunt about this method: it says the approximation "is likely to be visually very far from the actual printed result." Any conversion that ignores the output device shares that limitation, this one included.
Why your printer's numbers may differ
Professional layout and prepress software converts through an ICC profile, a file that describes how a specific press, ink set and paper behave. A common one for offset printing on coated paper in Europe is based on FOGRA39, a characterization data set from the German research organization FOGRA. Run #1E90FF through a profile like that and you'll usually get a different mix, because the profile is aiming for the closest color that press can actually make.
A sensible workflow for a brand color going to print:
- Convert the HEX here to get a ballpark CMYK for briefs and mockups.
- Ask the printer which ICC profile they use, or whether they'd rather receive RGB and convert it themselves.
- Do the final conversion in a profile-aware design app with that profile.
- Request a hard proof before a large run, and compare it to the color on a calibrated screen.
- If the color must match exactly across jobs and suppliers, consider a spot color. The HEX to Pantone tool suggests the nearest one as a starting point.
Darks and blacks
The naive formula always puts all darkness into K and leaves at least one of C, M or Y at zero. That gives some results a print operator would never choose:
| HEX | CMYK from this tool | Total ink |
|---|---|---|
#000000 |
0%, 0%, 0%, 100% | 100% |
#808080 |
0%, 0%, 0%, 49.8% | 49.8% |
#663399 |
33.3%, 66.7%, 0%, 40% | 140% |
#0A0000 |
0%, 100%, 100%, 96.1% | 296.1% |
#0A0000 is a near-black with a trace of red, yet the formula asks for full magenta and yellow plus 96% black. Presses limit total ink coverage, so a prepress conversion would handle that very differently. For pure #000000, many printers prefer a "rich black" that layers other inks under the K for depth on large areas. Ask yours what they want.
More conversions
| HEX | CMYK |
|---|---|
#FF0000 |
0%, 100%, 100%, 0% |
#FFA500 |
0%, 35.3%, 100%, 0% |
#2E8B57 |
66.9%, 0%, 37.4%, 45.5% |
#336699 |
66.7%, 33.3%, 0%, 40% |
#FFFFFF |
0%, 0%, 0%, 0% (no ink, paper white) |
Input rules
Enter one 3- or 6-digit code, with or without #, then press Convert. Invalid input, including alpha forms like #1E90FF80, gets "Enter a valid 3- or 6-digit HEX color, e.g. #1e90ff." The calculation runs in your browser.
To check how a CMYK spec will look on screen, go the other way with CMYK to HEX. If your color is already written as rgb(), RGB to CMYK skips the HEX step, and HEX to RGB shows the intermediate channel values.
Last updated