Image Color Palette Extractor

Pull the main colors out of any image as HEX and RGB codes.

🔒100% Private: files never leave your browser

Drop Your Image Here

To get colors from an image, upload it and pick how many you want, from 5 to 8. The tool shows the dominant colors with HEX and RGB codes you can copy with one click. It runs in your browser, so your image isn't uploaded.

What is a color palette extractor?

It looks at the pixels in a picture and reports the few colors that define it, ranked by how much of the image each covers. Instead of guessing by eye, you get exact codes for a photo, logo, or painting.

HEX and RGB are two ways to write the same color. RGB gives red, green, and blue from 0 to 255, like rgb(26, 43, 60). HEX packs the same three numbers into six characters, like #1A2B3C. Websites, design tools, and slides accept either.

Why pull colors from an image?

  • Match a brand's colors from its logo.
  • Build a website theme around a hero photo.
  • Make a mood board from a photo or painting.
  • Find shades to paint or shop for, based on a reference picture.

How to get the colors from a picture

  1. Click Select File, or drag an image into the drop zone.
  2. Choose how many colors you want from the menu. The palette appears right away.
  3. Click a swatch, or Copy HEX or Copy RGB, to copy a code. Use Copy all HEX codes or Copy as CSS variables to take them all.

How the colors are chosen

The tool shrinks the image, groups similar colors together, and picks the biggest groups while skipping near-duplicates, so the palette stays varied. The percentage shows how much of the picture each color covers. Fully transparent pixels are ignored, so a logo on a see-through background gives you the logo's colors.

Results are averages of similar shades, not one exact pixel. If a picture has only two colors, you get two swatches. To focus on one area, crop first with Crop Image. Want a black and white version? Try the Grayscale Converter.

Frequently asked questions

How do I get the HEX code of a color in an image?

Upload the image. Each dominant color appears with its HEX code, and clicking the swatch copies it.

Are these the exact colors in my picture?

They're averages of similar shades. For the exact color at one point, use an eyedropper tool.

Why do I get fewer colors than I chose?

The image may not have that many distinct colors, such as a simple logo.

Can I use the palette in CSS?

Yes. Click Copy as CSS variables and paste the block into your stylesheet.

What happens with transparent PNGs?

Transparent pixels are ignored, so only the visible colors count.

Is my image uploaded?

No. The colors are worked out in your browser.

From Our Blog

The Complete Guide to Image File Formats: PNG, JPG, WebP, HEIC, and SVG Explained

A plain-English breakdown of every major image format, what each one is actually good at, and how to pick the right one for the job.