Color Converter

Convert a color from hex, rgb(), hsl(), or a CSS color name to every common format. See a live preview swatch and copy-ready CSS values.

  • Runs entirely in your browser
  • No data stored or sent to a server
  • Free forever — no signup
  • Instant conversion

Input and Output

Use the interactive encoder and decoder on this page to process your text.

Learn more about color conversion

How to Convert Colors Between Formats

Color Conversion

Supported Input Formats

  • Hex: #RGB, #RRGGBB, #RRGGBBAA
  • RGB: rgb(59, 130, 246) or rgba(59, 130, 246, 0.5)
  • HSL: hsl(217, 91%, 60%) or hsla(...)
  • CSS names: common names like tomato, navy

When Developers Use This

Convert design handoff colors to CSS values, translate hex palette values to HSL for theming, or double-check rgba alpha channels during UI debugging.

Frequently asked questions

Does the preview update before I click Run?

Yes. The swatch updates live as you type a valid color. Click Run for the full format breakdown and copy-ready CSS.

Are all CSS color names supported?

Common named colors are supported. For uncommon names, use hex, rgb(), or hsl() instead.