Design & Color Tools
100% Client-Side 100% client-side privacy. All calculations and styling execute locally in your browser with zero server uploads.

RGB ↔ HSL Converter

Two-way converter between RGB color space and cylindrical HSL coordinates

🎛️ Color Studio•Electric Indigo

#6366F1

Luminance: 0.185•Contrast White: 4.5:1 ✗•Contrast Black: 4.7:1 ✓ AA
Recent Swatches:

Channel Tuning & Sliders

RGB Channels (0 - 255)
Red (R)99
Green (G)102
Blue (B)241
HSL Channels
Hue (H: 0° - 360°)239°
Saturation (S: 0% - 100%)84%
Lightness (L: 0% - 100%)67%
CMYK Channels (Print Inks 0% - 100%)
Cyan (C)59%
Magenta (M)58%
Yellow (Y)0%
Black / Key (K)5%

Formats & CSS Output

HEX
#6366F1
RGB / RGBA
rgb(99, 102, 241)
HSL / HSLA
hsl(239, 84%, 67%)
CMYK (Print)
cmyk(59%, 58%, 0%, 5%)
HSV / HSB
hsv(239, 59%, 95%)
CSS Custom Property
--color-primary: #6366F1;

Shades & Tints (Darker to Lighter)

About RGB ↔ HSL Converter

Convert RGB values to Hue, Saturation, and Lightness coordinates and vice versa with precision mathematical formulas and live visual preview.

Key Capabilities & Features

  • Simultaneous dual-pane conversion between RGB and HSL coordinates
  • Full hue angle calculation (0-360°) with percentage saturation and lightness
  • Accurate chromatic and achromatic color mapping
  • Export ready-to-paste CSS hsl() and rgb() syntax
  • Client-side execution with complete data privacy

How to Use RGB ↔ HSL Converter

1

Enter RGB or HSL

Modify the RGB or HSL channel sliders to see instantaneous conversions.

2

Check Surface Luminance

Review the calculated perceived brightness for your palette.

3

Copy CSS Declaration

Copy the formatted color definition directly into your project.

Privacy & In-Browser Execution Guarantee

100% client-side privacy. All calculations and styling execute locally in your browser with zero server uploads.

Frequently Asked Questions

What happens when Saturation is 0% in HSL?

When Saturation is 0%, the color is achromatic (grayscale), meaning Red, Green, and Blue are all equal and determined solely by the Lightness percentage.