CSS Color Format Converter
Convert sRGB colors between HEX, RGB, HSL, HWB and HSV or HSB. Inspect alpha, copy individual values and save a set of swatches as CSS or JSON.
Reading HEX8, HSL, HWB and HSV values
Preview composited on white. HEX stores alpha in 8 bits; decimal alpha is retained in RGB and HSL.
#7D9065rgb(125, 144, 101)hsl(86.512 17.551% 48.039%)rgb(49.02% 56.471% 39.608%)0.4902, 0.5647, 0.3961, 1--color: #7D9065;#7D9065FFhwb(86.512 39.608% 43.529%)hsv(86.512 29.861% 56.471%)Color names use standard CSS keywords, such as red or rebeccapurple.
CSS Color Format Converter: how to use it
- Enter a CSS color name, HEX code or numeric color function. For HSV use hsv(210 67% 60%).
- Inspect the RGB, HSL, HWB, HEX8 and HSV results. Adjust a channel to see how the values relate.
- Copy a single format or save swatches and download the collected colors as CSS or JSON.
Limits and notes
Works in 8-bit sRGB. Numeric alpha remains decimal in functional outputs and rounds to one byte in HEX8. HSV and HSB are design-tool notation. CSS variables, wide-gamut profiles and relative color expressions require other workflows.
How your privacy works →CSS Color Format Converter: common questions
How do I convert HSL to HEX?
Enter hsl(210 50% 40%). Its RGB channels are 51, 102 and 153, and the HEX result is #336699.
Is HSB different from HSV here?
Brightness and value name the same channel. Both input spellings accept a hue, saturation percentage and value percentage.