Free Online HEX to RGB Converter

Convert HEX Color Codes to RGB Instantly

Need to use HEX to RGB Converter right now?

HEX and RGB represent exactly the same color information in two different number formats — HEX uses base-16 (hexadecimal) notation compactly packed into a single string, while RGB expresses the same three color channels as separate base-10 numbers from 0 to 255. Converting between them is a lossless, exact mathematical operation, not an approximation.

No sign-upNo uploads 100% free
rgb(79, 70, 229)

79

Red

70

Green

229

Blue

Features

  • Runs entirely in your browser
  • Privacy-first — your data is never uploaded
  • Real-time, instant results
  • 100% free, no sign-up required
  • Works on desktop, tablet, and mobile
  • No installation needed

Who uses this tool?

DesignersDevelopersArtistsMarketers

About HEX to RGB Converter

HEX and RGB represent exactly the same color information in two different number formats — HEX uses base-16 (hexadecimal) notation compactly packed into a single string, while RGB expresses the same three color channels as separate base-10 numbers from 0 to 255. Converting between them is a lossless, exact mathematical operation, not an approximation.

This tool takes any HEX color code — with or without the leading #, and supporting both 6-character (#4f46e5) and shorthand 3-character (#4fe) formats — and converts it to its exact RGB equivalent, showing the red, green, and blue channel values individually alongside the full rgb() CSS syntax.

This conversion comes up constantly when moving a color value between contexts that expect different formats — a design tool exports HEX, but a canvas drawing operation or certain JavaScript color libraries expect RGB values as separate numbers rather than a single hex string.

This is useful for web development requiring RGB format specifically, understanding a HEX color's individual red/green/blue intensity, or converting a color picked from a design tool into the exact numeric format your code needs.

How it works

  1. Enter a HEX color code. With or without the #, in 6-character or 3-character shorthand form.
  2. View the RGB equivalent. Both the full rgb() syntax and individual channel values.
  3. Copy the result. Ready to paste directly into your code.

Examples

Standard 6-character HEX

Input

#4f46e5

Output

rgb(79, 70, 229)

Shorthand 3-character HEX

Input

#fff

Output

rgb(255, 255, 255)

Frequently asked questions