Nifty / Tools / Color

RGB to HEX

Convert RGB colors to HEX, one per line. Switch Convert to for HSL, OKLCH, Lab or every format at once.

rgb-to-hex
RGB colorsDrop a file here
HEX colors
Loading…

Runs in your browser. Nothing you paste is uploaded or stored.

How to use the RGB to HEX

  1. Paste one or more colors on the left, one per line. Any CSS color works as input, including names like rebeccapurple.
  2. Keep HEX or pick another format under Convert to.
  3. Copy the converted colors.

Questions

Is my data uploaded anywhere?

No. The tool runs entirely in your browser. Nothing you paste or drop is sent to a server, logged or stored, so it's safe for API responses, config files and other private data.

What about transparency?

Alpha is kept: #1e293bcc becomes rgba(30, 41, 59, 0.8) and back again.

Can I convert colors in VS Code?

Yes. Nifty Colors shows a swatch next to every color in your code and converts it to hex, RGB, HSL or OKLCH from the Command Palette, in CSS, Tailwind, Flutter, Android, Swift and more.

Related tools