A color photo with an extracted HEX and RGB palette of swatches

Image Color Palette

Extract HEX, RGB and HSL colors from a photo. Copy CSS or download a PNG swatch card. It all runs in your browser — your image is never uploaded.

Drop images to extract a color palette

JPG · PNG · WebP · HEIC · AVIF — one file or a batch of up to 50

or paste an image with Ctrl+V / ⌘V

Privacy: Decoding the image, building the palette and saving the file all run in your browser. Your files are not uploaded to our servers. The page loads JSZip and, for HEIC files, open-source HEIC decoders from a public CDN; your image is not sent to it.

Extract a Color Palette From a Photo

Need a starting palette for a brand, a listing, or a website? This tool scans your photo in the browser and pulls out the main colors as HEX, RGB and HSL. You can copy the list, grab CSS variables, or download a PNG swatch card.

JPG, PNG, WebP, iPhone HEIC and AVIF are all accepted. Nothing is uploaded. If you only need the exact color of one pixel, use the Color Picker instead.

How to extract a color palette from an image

  1. Add your image. Drop a JPG, PNG, WebP, iPhone HEIC or AVIF file, or choose it from your device. You can add up to 50 images in one batch.
  2. Choose how many colors you want. The default is 8. Raise or lower the slider if you want a tighter or larger set.
  3. Copy or download. Click a swatch to copy its HEX code, copy the whole palette as CSS or JSON, or download a PNG swatch card. Several images save together as a ZIP.
  4. Optional: Turn on “Ignore near-white pixels” if a white backdrop is crowding out the colors you care about.

Related tools

  • Color Picker: click any pixel to read its exact HEX, RGB and HSL values.
  • Image Converter: convert JPG, PNG, WebP, GIF, AVIF and iPhone HEIC in your browser.
  • SVG Icon Maker: use a palette color when you make a simple SVG icon.
  • Grayscale Image: convert the same photo to grayscale or black and white.

To redraw the same photo with a limited palette, use the free Simplify Image tool. It also runs in your browser, with no upload.

Frequently Asked Questions (FAQ)

Q: How do I extract a color palette from an image?

A: Add your image, choose how many colors you want, and the palette appears automatically. Click a swatch to copy its HEX code, or download a PNG swatch card.

Q: How many colors can I extract?

A: You can ask for 2 to 16 colors. The default is 8. If the image only uses a few flat colors, you will get fewer swatches than you asked for, which is expected.

Q: Can I use an iPhone HEIC photo?

A: Yes. You can add JPG, PNG, WebP, iPhone HEIC/HEIF and AVIF. HEIC and AVIF are decoded in your browser. Transparent pixels are skipped, and you can also ignore near-white backgrounds.

Q: What do HEX, RGB and HSL mean?

A: HEX is the six-digit web color code, such as #DC1414. RGB is the same color as red, green and blue values from 0 to 255. HSL describes hue, saturation and lightness, which is handy when you are adjusting a color in CSS.

Q: Can I copy the colors or download a swatch card?

A: Yes. Click a swatch to copy its HEX value. You can also copy the whole palette as a HEX list, CSS variables or JSON, or download a PNG swatch card. Several images download together as a ZIP of cards.

Q: Are my images uploaded?

A: No. Decoding the image, building the palette and saving the file all happen in your browser. Your files are not uploaded to our servers.

Q: How is this different from the Color Picker?

A: The Color Picker reads the exact color of one pixel you click. This tool scans the whole image and builds a palette of the main colors automatically. Use the picker when you need one precise sample; use this page when you want a starting palette.

Q: Can I extract palettes from several images at once?

A: Yes. Add up to 50 images, review each palette, and download them as a single ZIP of PNG swatch cards. A bad file is skipped with an error and the rest of the batch continues.