Numbers & representations

Color Converter

Convert CSS HEX, RGB, HSL and named colors. Preview each color and preserve its alpha channel.

Stays in your browserFiles and text are processed in this tab.
Color ConverterLocal processing
Enter at least one value.

Numbers & representations

How it works

RGB describes red, green and blue light. HEX writes those channels as hexadecimal bytes. HSL describes hue, saturation and lightness. Alpha controls transparency and is separate from lightness.

What you can do

Paste one CSS color per line, choose HEX, RGB or HSL output, and convert. The first color shows all three forms. The checkerboard behind each swatch makes partial transparency visible.

How to use it

  1. Select HEX, RGB or HSL output. Input format is detected automatically; for #336699 → rgb(51, 102, 153), choose RGB.
  2. Paste one value per line or open a UTF-8 text file.
  3. Select Convert, inspect the result, then copy or download TXT. Changes clear old results. Undo restores your previous input and settings.

Errors and limits

Supported syntax includes short/long HEX, RGB percentages, HSL and standard color names. RGB bytes must be 0–255; alpha 0–1 or 0–100%. HEX alpha is the final byte (RRGGBBAA). HWB, Lab, color() and relative colors are not supported. Conversions round to 8-bit RGB.

Limits: 200,000 input characters, 500 values and 1,000,000 output characters. The entire batch stops on an invalid line.

Frequently asked questions

Does #33669980 mean 80% opacity?

No. The suffix 80 is hexadecimal 128, so alpha is 128/255, approximately 50.2%. For exactly 80% opacity, use rgba(51, 102, 153, 0.8).

Are my values uploaded?

No. Processing and file reading happen in this browser tab. Values are not placed into URLs or sent to a conversion service. Downloaded files remain under your control.

Related tools