RGB to HEX Converter

Enter red, green and blue values to get the HEX colour code instantly, or convert a whole list.

FreeNo sign-upRuns in your browserMobile-friendly

Loading tool…

Need help with this tool or found a problem? WhatsApp support Email

What does the RGB to HEX Converter do?

Each RGB channel (0–255) is converted to two hexadecimal digits and joined: rgb(79, 70, 229) → #4F46E5. Add an alpha value below 1 to get an 8-digit HEX code with transparency.

The bulk box accepts lines like rgb(255, 87, 51) or 0,128,255 and converts them all at once.

How to use the RGB to HEX Converter

  1. Enter R, G and B values (0–255) and optional alpha.
  2. Copy the HEX code.
  3. For many colours, paste them into the bulk box.

Examples

Conversion

rgb(0, 128, 255) → #0080FF.

Common use cases

  • Writing CSS from design specs
  • Converting screenshots’ RGB readings
  • Preparing brand guidelines

Features and benefits

  • Private by design — your data is processed on your device and never uploaded.
  • Free with no account, no watermark and no usage limits.
  • Works on phones, tablets and desktops in any modern browser.

Limitations to know

  • Values outside 0–255 are rejected.

Frequently asked questions

How do I convert RGB to HEX?

Convert each number to base 16 and pad to two digits: 255 → FF, 0 → 00.

Uppercase or lowercase?

Both are valid in CSS; choose your preference.

What about alpha?

An alpha below 1 adds a fourth hex pair.

Embed this tool on your website

Add the free RGB to HEX Converter to your blog or website. Paste the code into your page’s HTML; the tool runs in your visitors’ browsers and stays up to date automatically. Please keep the credit line below the tool.

Free to use on any website. The tool runs inside an iframe served from viptools.pk; nothing your visitors type is sent to your site or ours. Preview the embedded version.