Free colour tools

RGB to HEX, HEX to RGB & HSL Converter

Convert RGB to HEX, HEX to RGB or HSL in either direction. Type a value into any field to see all three formats, preview the colour and copy CSS-ready codes.





Type a value then press Enter or click outside the field to convert.

When should I use HEX, RGB or HSL?

HEX represents red, green and blue channels in a compact code, such as #536B58. RGB expresses those same channels as three numbers between 0 and 255. HSL represents a hue angle, saturation and lightness, which can make controlled colour adjustments easier.

These formats describe screen colours; converting between them does not guarantee the same printed result. For print production, discuss the output colour profile with your printer.

RGB to HEX conversion examples

Enter rgb(83, 107, 88) in the RGB field to get #536B58. A pure red value of rgb(255, 0, 0) becomes #FF0000, while rgb(0, 0, 255) becomes #0000FF. You can also type bare RGB values such as 83, 107, 88.

Going the other way, #FFFFFF equals rgb(255, 255, 255) and #000000 equals rgb(0, 0, 0). These are screen-colour representations, not print-colour conversions.

How to convert an RGB colour into HEX

  1. Enter three red, green and blue channel values, each between 0 and 255.
  2. Press Enter or click outside the field.
  3. Copy the matching six-digit HEX value, including its leading #.

For colour inspiration, explore the palette library or view website colour scheme previews.