D3.js Color

D3.js provides many methods and function to transform colors between hex, rgb, hsl, css color name, hcl, lch, and cubehelix. It would be a good idea to implement d3's functions for transfering colors rather than trying to implement my own. Below, you can edit color values and copy the resulting coplor values.
To change between having the main color be represented as hex / rgb / hsl / css color name / hcl / lch / cubehelix, edit the Main Color Representation select input.

Output Color

  • Hex: #004da3
  • RGB:
  • HSL:
  • CSS Color Name:
  • HCL:
  • LCH:
  • Cubehelix:
  • LAB:

Input Color

Main Color Representation:
#004da3
CSS Color Select:
1

RGB Picker

HCL Picker

LCH Picker

HSL Picker

Lab Picker