← All guides

HEX vs RGB vs CMYK (and Pantone): which color code to use where

From the Encosta Lenta example brand book

Every brand book lists colors in several codes: HEX, RGB, CMYK and sometimes Pantone. They describe the same color for different places. Use the wrong one and your logo comes back from the printer looking muddy, or your website shows a slightly different shade from your business card.

Here's what each code means and when to use it, with Encosta Lenta's wine red, #5E1F2B, as the running example.

The short answer

CodeExampleUse it for
HEX#5E1F2BWebsites, apps, design tools
RGB94 31 43Screens, video, digital design apps
CMYKC0 M67 Y54 K63Printing with regular ink
PantoneA named spot colorExact print matches on labels, signs and packaging

RGB: color made of light

Screens mix red, green and blue light. RGB gives the amount of each, from 0 to 255. Wine red is 94 red, 31 green and 43 blue: mostly red, a little blue, very little green, and fairly dark overall.

Use RGB for anything on a screen: websites, apps, social media images, presentations and video.

HEX: RGB written for the web

A HEX code is the same RGB values written in a shorter form. #5E1F2B is three pairs: 5E for red, 1F for green, 2B for blue, each a number from 0 to 255 written in base 16.

HEX and RGB describe exactly the same color, so you can convert between them without any loss. Web developers and design tools prefer HEX because it's one short string you can copy and paste.

CMYK: color made of ink

Printers don't use light. They layer cyan, magenta, yellow and black ink (K stands for "key", the black plate). CMYK gives the percentage of each ink. Wine red is 0% cyan, 67% magenta, 54% yellow and 63% black.

Use CMYK for anything printed on a regular press: business cards, flyers, menus, brochures, labels.

Why your color looks different in print

Light on a screen can make colors that ink on paper can't. Very bright blues, greens and oranges are the usual victims: they look vivid on screen and dull in print. Paper matters too. The same CMYK values look brighter on coated paper than on uncoated paper.

That's why a CMYK code converted from a screen color is a starting point, not a promise. Before a large print run, ask your printer for a proof and adjust if needed. Once you've found values that print well, write them in your brand book so nobody has to repeat the test.

Pantone: the exact match

Pantone is a library of premixed ink colors, each with a name and number. Instead of building a color from four inks, the printer uses one ink mixed to an exact recipe, so it looks the same from job to job and printer to printer.

Use Pantone when consistency on paper really matters: packaging, labels, signage, merchandise. It usually costs more than CMYK printing, so many small brands use CMYK for everyday print and Pantone only for packaging.

What to put in your brand book

For every brand color, list:

  • HEX for web and design tools.
  • RGB for screens and digital apps.
  • CMYK for print, ideally values you've checked with a proof.
  • Pantone if you print packaging, labels or signs.

Here's how Encosta Lenta's book shows its colors, each with HEX, RGB and CMYK side by side:

Identitas books list HEX, RGB and CMYK for every color automatically, and you can copy any code with one click.

Frequently asked questions

Is HEX the same as RGB?

Yes. A HEX code is RGB written in a shorter form, base 16 instead of base 10. #5E1F2B and RGB 94 31 43 are exactly the same color.

Both. Keep RGB or HEX versions for screens and CMYK versions for print. Most brand books list both codes for every color, and many keep separate logo files for each.

Why does my printed color look different from my screen?

Screens make color with light and printers with ink, and ink can't reproduce every color a screen can. Paper type changes the result too. Ask your printer for a proof before large runs.

See your own brand as a book.

Paste your website. The scan is free and takes about a minute.

Keep reading