Color ConverterOn-device processing

Preparing your tool…

How to use it

  1. 01Enter a HEX, RGB or HSL color, such as #2f5bff or rgb(47, 91, 255).
  2. 02Select Convert color, or press Enter.
  3. 03Check the preview and copy HEX, RGB or HSL.

Useful details

Accepted inputs include 3, 4, 6 and 8-digit HEX, numeric or percentage RGB, HSL hue in degrees and optional alpha as a fraction or percentage. Hue wraps around 360 degrees. RGB channels round to 8-bit values, HSL displays one decimal place and alpha displays three, so round trips can differ slightly. Named colors, CSS variables, wide-gamut spaces and CSS calc expressions are not accepted. This is a format conversion tool, not a contrast or color-management checker.

Questions about this tool

Can I convert a color with transparency?

Yes. Short and long HEX alpha, RGBA and HSLA are supported. Outputs include alpha when it is below 1.

Why do values change slightly after converting back?

RGB rounds to whole 8-bit channels, and HSL and alpha use display precision. Small rounding differences are expected.

Can I use a named CSS color or variable?

No. Enter a concrete HEX, RGB or HSL value.