Color Converter

Convert any color to every format

Paste a color in any format — HEX, RGB, HSL, HSV, OKLCH, CMYK or a named color — and get all the others instantly. Edit any field to convert from that format. Free, no signup.

#F54927
HEX
RGB
HSL
HSV
OKLCH css
CMYK
Mobile / native tokens
SwiftUI
UIKit
Flutter / Dart
Jetpack Compose
Android XML

How to convert color codes

Type or paste any color into the box — #f54927, rgb(245, 73, 39), hsl(10, 91%, 56%), hsv(10, 84%, 96%), oklch(0.65 0.21 33), cmyk(0%, 70%, 84%, 4%) or a name like tomato. Every other format updates instantly. You can also edit any individual field to convert from that format outward.

What each format is for

HEX & RGB

The two most common web formats. They store the same red, green and blue values; HEX is just shorter, which is why CSS and design tools default to it.

HSL & HSV

Human-friendly models built on hue, saturation and lightness or brightness. Ideal when you want a lighter, darker or less vivid version of a color.

OKLCH

The modern, perception-based CSS format. Lightness and chroma behave consistently across hues, which makes it excellent for design systems. Supported in all current browsers.

CMYK

The print format — cyan, magenta, yellow and key (black). Useful as an on-screen reference, though exact print color depends on your printer's ICC profile.

How accurate are the conversions?

Conversions between HEX, RGB, HSL and HSV are exact and reversible — they describe the same sRGB colour in different notations, so nothing is lost going back and forth. OKLCH conversions are computed through the OKLab colour space using the standard transform, accurate to the precision shown. CMYK is the one to treat as a reference rather than a guarantee: screens are additive (RGB) and print is subtractive (CMYK), and true print colour depends on inks, paper and your printer's colour profile. For on-screen work, every value here is reliable.

Two-way conversion

This converter isn't one-directional. Every format field is editable, so you can convert from any format, not just to it. Type into the HSL field and the HEX, RGB, OKLCH and CMYK values all recalculate from it; paste an OKLCH value and everything else follows. That makes it easy to take a colour you already have in one notation and read it in whichever your project needs — no need to chain separate tools.

When you'd convert colours

Common reasons developers and designers convert: turning a designer's HEX into RGB or HSL for code, adapting a brand colour into OKLCH for a modern design system, getting CMYK reference values before sending artwork to print, or translating a named colour into an exact code. Whatever the direction, paste it in and read off the rest.

Frequently asked questions

How do I convert a color code?
Paste any color into the input — HEX, RGB, HSL, HSV, OKLCH, CMYK or a named color. Every other format updates instantly. You can also edit any field directly to convert from that format.
Can I convert from OKLCH to HEX?
Yes — type an oklch() value and the converter shows the matching HEX, RGB, HSL, HSV and CMYK, and the reverse works too.
Is CMYK conversion accurate for printing?
It uses the standard RGB-to-CMYK math, correct for on-screen reference. Exact print output depends on your printer's colour profile, inks and paper.
Can I convert a named color like "tomato"?
Yes — type the name and the converter resolves it to HEX and every other format. It understands all 140 CSS named colours.
Does converting lose any accuracy?
No for HEX, RGB, HSL and HSV — they are exact, reversible representations of the same colour. OKLCH uses the standard precise transform, and CMYK is an on-screen reference.

More color tools

Color Picker →
Pick visually, get every code.
Contrast Checker →
WCAG AA/AAA pass-fail.
Color-Blindness Sim →
See palettes through 8 CVD types.
Color Codes →
Named colors, charts, game codes.