Color converter

Enter a color in any format or pick one, and get HEX, RGB, HSL and CMYK values instantly, plus contrast ratios for accessible text.

Private: works in your browser, nothing is uploaded.

How to use the Color Converter tool

  1. Type a color like #0071E3, rgb(0,113,227), hsl(211,100%,45%) or a name like tomato.
  2. Or use the color picker.
  3. Copy the format you need.

Color formats explained

  • HEX (#0071E3): the standard for web design and CSS. Two hexadecimal digits each for red, green and blue.
  • RGB (0, 113, 227): the same red, green and blue values in decimal, from 0 to 255.
  • HSL (211°, 100%, 45%): hue, saturation and lightness. Easy to adjust: change only the lightness to get darker or lighter shades of the same color.
  • CMYK: cyan, magenta, yellow and black, used in printing. Screen and print colors never match perfectly, so treat converted CMYK as a starting point and check with your printer.

Contrast for readable text

The Web Content Accessibility Guidelines (WCAG) recommend a contrast ratio of at least 4.5:1 for normal text and 3:1 for large text. The converter shows the ratio of your color against white and against black, so you can see immediately which text color works on it.

Privacy

Everything you type stays in your browser. Nothing is sent to a server or stored.

Building a palette from one colour

HSL makes it easy to create matching shades. Keep the hue the same and change only the lightness to get lighter backgrounds and darker hover states, for example 45% for the main colour, 35% for hover and 95% for a light tint behind text. Lowering the saturation gives calmer versions of the same colour for borders and secondary elements.

Brand colours in different places

  • Websites and apps: HEX or RGB.
  • Office documents and presentations: RGB values in the custom colour dialog.
  • Printed material: CMYK values or a Pantone reference from your designer or printer.
  • Embroidery, paint and signs: suppliers usually match Pantone or RAL colours, so ask for the nearest match.

Frequently asked questions

How do I convert HEX to RGB?

Paste the HEX code into the input box. The RGB value appears instantly and can be copied.

Does it accept CSS color names?

Yes. Names like navy, tomato or rebeccapurple are converted to all formats.

Is the CMYK value exact?

It is a mathematical conversion without a printer profile. For exact print colors, ask your printer for their profile.

Can I enter a 3-digit HEX code?

Yes. #0AF is read as #00AAFF.

Why does my colour look different on another screen?

Screens differ in calibration and colour range. The colour values are the same; how they look depends on the display.

What is the alpha value in RGBA and HSLA?

Alpha is transparency, from 0 (invisible) to 1 (solid). It is useful for overlays and shadows in CSS.