HEX to RGB Converter

Convert HEX color codes to RGB. Useful for CSS, design systems, and tools that don't accept hex.

Converter
Direct answer

Paste a hex color (#FF0000 or FF0000). Each pair of hex digits is one channel: #FF0000 → rgb(255, 0, 0).

Ad
HEX input
RGB output

About HEX → RGB

CSS and design files use hex, but JavaScript canvas and some image-processing APIs want RGB tuples. Converting also helps when you need to apply opacity (rgba) which hex shorthand doesn't support cleanly.

Ad

Frequently asked questions

What about 3-digit hex like #F00?
Each digit doubles up: #F00 = #FF0000 = rgb(255, 0, 0). This converter expands shorthand automatically.
How do I add transparency?
Use rgba(r, g, b, alpha) where alpha is 0-1. Or use 8-digit hex: #FF000080 = 50% red.

Related tools