Color Format Converter

Convert any CSS color between HEX, RGB, HSL, and OKLCH with one-click copy and light/dark previews.

Showing exact conversions for #8fd14f.

Sample on light surface
Sample on dark surface

HEX

#c6fb50

RGB

rgb(198 251 80)

HSL

hsl(79 95% 65%)

OKLCH

oklch(0.918 0.197 125.7)

About Color Format Converter

Color Format Converter translates CSS colors between traditional sRGB notations and modern perceptual oklch() values completely on your device.

How it works

  1. Enter a color in HEX, rgb(), hsl(), or oklch(), or use the native color picker.
  2. Preview how the swatch looks against both light and dark backgrounds.
  3. Copy any converted CSS color string in one click.

Privacy and precision

  • Local math: OKLCH conversions follow the standard linear sRGB to OKLab matrix transform inside your browser.
  • Gamut indicator: Out-of-gamut OKLCH inputs are flagged automatically when clamped to sRGB for display.