Color
HSL to HEX Converter
Convert HSL colors to HEX color codes online. Enter hue, saturation and lightness values and get a copyable HEX code with preview.
Tool
Convert HSL colors to HEX color codes online. Enter hue, saturation and lightness values and get a copyable HEX code with preview.
This tool runs in your browser. Your input is processed locally and is not uploaded.
About this Tool
Use this free HSL to HEX converter to turn hue, saturation and lightness values into a hexadecimal color code. It is useful for converting CSS hsl() colors into HEX values for design tools, documentation and older CSS workflows.
Examples
- hsl(12, 100%, 60%)
- hsl(217, 91%, 60%)
- 120, 70%, 45%
- hsl(0, 0%, 100%)
Frequently Asked Questions
How do I convert HSL to HEX?
The HSL value is first converted to RGB, then each RGB channel is converted into a two-character hexadecimal value.
What HSL values are valid?
Hue is usually a number from 0 to 360 degrees. Saturation and lightness are percentages from 0% to 100%.
Can I paste CSS hsl() values?
Yes, the tool should accept CSS-style hsl() input as well as plain HSL channel values.
Is HEX better than HSL?
Neither is always better. HEX is compact and widely used, while HSL is easier to adjust when creating color variations.