Color Converter — HEX, RGB, HSL, CMYK and More
Convert between color formats instantly — HEX to RGB, RGB to HSL, CMYK to HEX. A practical guide to color models for designers and developers.
Every designer, developer, and marketer eventually needs to convert a color from one format to another. Your design tool exports HEX, your CSS needs RGB, the print shop wants CMYK, and your brand guidelines list HSL values. They all describe the same color — just in different languages.
The CalcHub color converter handles HEX, RGB, HSL, and CMYK conversions instantly.
The Four Main Color Models
HEX (Hexadecimal)
Format:#RRGGBB (e.g., #FF5733)
Each pair of hex digits represents red, green, and blue intensity from 00 (none) to FF (maximum). This is the standard in web development and design tools.
- #000000 = Black
- #FFFFFF = White
- #FF0000 = Pure Red
- #00FF00 = Pure Green
- #0000FF = Pure Blue
RGB (Red, Green, Blue)
Format:rgb(255, 87, 51) or (R, G, B) with values 0–255
Identical information to HEX, just in decimal. Every screen pixel is a combination of red, green, and blue light at varying intensities.
HSL (Hue, Saturation, Lightness)
Format:hsl(14, 100%, 60%) — H: 0–360°, S: 0–100%, L: 0–100%
HSL is more intuitive for color manipulation:
- Hue = the color itself (0° = red, 120° = green, 240° = blue)
- Saturation = how vivid (0% = gray, 100% = full color)
- Lightness = how bright (0% = black, 50% = pure color, 100% = white)
Want a darker version of a color? Reduce lightness. Want a muted version? Reduce saturation. This is much harder to do intuitively with HEX or RGB.
CMYK (Cyan, Magenta, Yellow, Key/Black)
Format:(0, 66, 80, 0) — values 0–100%
CMYK is the print color model. Screens add light (RGB is additive); printers add ink (CMYK is subtractive). A color that looks perfect on screen may shift in print because the gamuts don't perfectly overlap.
Quick Conversion Reference
| Color | HEX | RGB | HSL | CMYK |
|---|---|---|---|---|
| Pure Red | #FF0000 | (255, 0, 0) | (0°, 100%, 50%) | (0, 100, 100, 0) |
| Navy Blue | #000080 | (0, 0, 128) | (240°, 100%, 25%) | (100, 100, 0, 50) |
| Forest Green | #228B22 | (34, 139, 34) | (120°, 61%, 34%) | (76, 0, 76, 45) |
| Orange | #FFA500 | (255, 165, 0) | (39°, 100%, 50%) | (0, 35, 100, 0) |
| Purple | #800080 | (128, 0, 128) | (300°, 100%, 25%) | (0, 100, 0, 50) |
| Teal | #008080 | (0, 128, 128) | (180°, 100%, 25%) | (100, 0, 0, 50) |
Practical Applications
Web Development
CSS supports all three screen-based models:color: #FF5733;
color: rgb(255, 87, 51);
color: hsl(14, 100%, 60%);
Use HEX for static colors, HSL when you need to programmatically adjust shades (dark mode, hover states, theme variants).
Design Systems
Brand colors are typically defined in HEX with HSL variants for generating consistent shade palettes:- Primary: hsl(220, 80%, 50%) — the base
- Light variant: hsl(220, 80%, 70%) — increase lightness
- Dark variant: hsl(220, 80%, 30%) — decrease lightness
- Muted variant: hsl(220, 30%, 50%) — decrease saturation
Print Design
Always convert to CMYK before sending to print. Screen colors (RGB) often appear duller in CMYK because print has a smaller color gamut. Bright neons and vivid blues are particularly affected — they can't be reproduced in standard four-color printing.Accessibility
Color contrast ratios (WCAG guidelines) are calculated from RGB values. Minimum ratios:- Normal text: 4.5:1 contrast ratio
- Large text: 3:1 contrast ratio
- UI components: 3:1 contrast ratio
How to Use the CalcHub Color Converter
- Open the Color Converter
- Enter your color in any supported format
- See instant conversions to all other formats
- Copy the value you need
Why does my screen color look different when printed?
Screens use light (RGB, additive mixing) while printers use ink (CMYK, subtractive mixing). The color gamuts don't fully overlap — some screen colors (especially vivid blues, greens, and neons) can't be reproduced in CMYK. Always proof print colors before finalizing.
What does the "A" in RGBA and HSLA mean?
Alpha — transparency. A value from 0 (fully transparent) to 1 (fully opaque). rgba(255, 0, 0, 0.5) is red at 50% opacity. In HEX, you can add two digits: #FF000080 (last two digits = alpha).
Which color model should I learn first?
HEX for web work (you'll see it everywhere). HSL for understanding color relationships (hue, saturation, lightness are intuitive). CMYK only if you do print work. RGB is automatic if you understand HEX.
Related Tools
- Text to Hex Converter — encode text as hex
- Number Base Converter — convert between hex, decimal, binary
- Percentage Calculator — calculate color percentages