Color Converter
Convert between HEX, RGB, and HSL color formats.
Related tools
Convert colours between HEX, RGB, and HSL formats in your browser, with a live preview. Grab the exact value you need for CSS, design tools, or brand guidelines.
Frequently asked questions
What’s the difference between HEX, RGB, and HSL?
HEX and RGB describe a colour by red, green, and blue channels; HSL describes it by hue, saturation, and lightness, which is easier to adjust intuitively.
Which format should I use in CSS?
All three work in modern CSS. HEX is compact, RGB supports alpha via rgba(), and HSL makes tweaking shades simple.
Can I get a transparent colour?
Not with this tool. It reads and writes opaque colors only, so rgba(), hsla() and 8-digit HEX values are rejected. Convert the color here, then add the alpha value in your CSS.
Which color formats can I type in?
HEX with 3 or 6 digits (#f53 or #ff5733), rgb(255, 87, 51) and hsl(14, 100%, 60%). You can also choose a color with the color picker. Each valid input is converted to all three formats at once. Color names such as red and the space-separated CSS syntax are not accepted.