Free tool

Extract a color palette from an image

Drop a photo, painting or screenshot and this free tool finds its 5 to 30 main colors, with each color's hex code and the share of the image it covers. Click the image to add a color it missed, reorder or remove any, then download the palette for Procreate, Photoshop, Clip Studio Paint, Krita or GIMP, or as hex codes and CSS. The image is never uploaded.

Last updated

Drop an image to get its colors

  • Never uploaded
  • Free, no account

Step by step

  1. Drop an image

    Drop a PNG, JPG, WebP, GIF, BMP or AVIF file above, or a .procreate or .psd file. The main colors appear next to it, most common first.

  2. Choose how many colors

    Move the slider from 5 to 30. The colors are found again each time, and colors you added by hand stay.

  3. Edit the palette

    Click the image to add the color under the pointer, or type a hex code. Select a color to move, copy or remove it, or sort the whole palette by amount, hue or lightness.

  4. Download it

    Pick .swatches for Procreate, .ase or .aco for Photoshop and Clip Studio Paint, .gpl for GIMP, .kpl for Krita, or hex codes and CSS for code.

How do I get hex codes from an image?

Drop the image and every color in the palette shows its hex code. Select a color to copy its code, or download all of them at once as a Hex codes text file or as CSS variables.

To get the exact code of one spot, such as a logo color or a skin tone, click that spot on the image. The color under the pointer is added to the palette as it is, not averaged into a group. On images larger than 1,200 pixels it comes from the scaled copy described below, so pick from the middle of a flat area rather than an edge. You can also type a hex code to add a color the image doesn’t have.

How do I make a Procreate palette from an image?

On the iPad, Procreate can do it itself. The Procreate Handbook lists three ways in the Palettes tab: New from Camera, New from Photos (“Tap a photo and Procreate will create a customized palette from the colors captured within that photo”) and New from File for a JPG or PNG. If you only need a quick palette on the iPad, that is the fastest route.

Use this page instead when:

  • You are on a computer, or the reference image is on a computer.
  • You want to choose how many colors, drop the ones you don’t need, add a color by clicking it, and put them in order before the palette goes to the iPad.
  • You need the same palette in Photoshop, Clip Studio Paint, Krita, GIMP or in code, where Procreate’s palette feature doesn’t help.

Download the .swatches file, send it to the iPad, and drag it into the Palettes tab under Colors.

Which file do I need for Photoshop and other apps?

App Download Import from
Procreate .swatches Drag it into the Palettes tab under Colors
Photoshop .ase or .aco Swatches panel menu > Import Swatches
Illustrator, InDesign, Affinity .ase The Swatches panel menu
Clip Studio Paint .aco Color Set palette menu > Import color set
Krita .kpl Palette docker > Import resources
GIMP, Inkscape .gpl Palettes dialog > Import Palette
Websites, code, notes Hex codes or CSS Paste them

Procreate’s handbook says it imports a .swatches file by drag and drop into the Palettes tab, and .ase and .aco files through New from File, so the Adobe downloads work on the iPad too. Each color in the Adobe, GIMP and Krita files is named after its hex code. The PNG card is a picture of the palette with the hex code under each color, for a mood board or a client. Moving the palette into Clip Studio Paint or Krita along with your artwork? The guides to opening Procreate files in Clip Studio Paint and in Krita cover the layers.

The procreate-swatch-generator project notes that Procreate swatches “only support up to 30 colors”, which is why the slider stops at 30 and clicking the image stops adding colors once the palette is full.

How does it pick the colors?

It groups pixels by how alike they look, then gives each group’s average color. The steps:

  1. Every pixel at least half opaque is counted into 32,768 bins (32 levels each of red, green and blue), keeping the exact average color of each bin.
  2. The bins are compared in OKLab, a color space where equal distances look like roughly equal differences, so two blues that look alike are grouped even if their numbers differ.
  3. Median cut splits the colors into as many groups as you asked for, always splitting the group with the widest spread.
  4. A few rounds of k-means move each color to the middle of the pixels nearest to it.
  5. Each color is the average of its pixels, so a flat area in a drawing comes back as its exact hex code.

Images larger than 1,200 pixels on the longest side are counted on a scaled copy of that size, which keeps it fast on phones. The share shown for each color is the part of the counted pixels nearest to it.

Painting from a reference photo

A palette tells you which colors are in a photo, not how light or dark they are. To see the light and dark pattern of the same reference, run it through the value checker, which shows it in grayscale or in 2 to 5 values, or the notan generator, which cuts it down to flat dark and light shapes.

What this tool doesn’t do

  • No color names. Colors are named by hex code, not “dusty rose”. Rename them in your app if you need to.
  • No color schemes. It finds the colors that are in the image; it doesn’t invent complementary or analogous colors.
  • No RGB, HSL or CMYK lists. The text downloads are hex codes and CSS. The palette files store RGB, and your app shows the other values once imported.
  • No print matching. Colors are sRGB as the browser decodes the image. There is no CMYK or Pantone matching, and an image tagged with a wide-gamut profile such as Display P3 is converted to sRGB by the browser first.
  • One image at a time. Drop another image to start a new palette.

For a palette file you already have in another format, use the ASE and ACO palette converter. For a palette exported from Procreate, the Procreate swatches converter opens .swatches files.

How this page was tested

On 15 October 2026 we ran the tool in headless Chrome on a Linux desktop with test images we made ourselves:

  • Flat colors. A 400 × 100 px PNG with four flat colors covering 40%, 30%, 20% and 10% of it came back as exactly those four hex codes, with those shares, most common first.
  • Clicking the image. On a 256 × 200 px test image where each pixel’s red and green values equal its position, clicking five known points added the exact color of each point.
  • Transparency. A PNG with one green square on a transparent background gave one color, the green; the background was ignored.
  • A large photo-sized file. A 4000 × 3000 px JPG took 0.3 seconds from dropping it to showing 8 colors, decoding included. Moving the slider to 30 colors took 0.2 seconds.
  • Procreate and Photoshop files. On 17 October 2026 the two sample .procreate files the converter offers to try gave their palettes in about half a second and about one second, and a layered .psd test file gave its palette too. A file that ends in .procreate but isn’t one showed an error instead of a palette.
  • The downloads. We read every file back with separate readers written from the format descriptions (ZIP and JSON for .swatches, Adobe’s specification for .aco and .ase, plain text and XML for the rest). Every color, in the order we set, matched the palette on screen, and the PNG card showed the same hex values.

We have not yet imported the files into Procreate on an iPad or into Photoshop, Clip Studio Paint, Krita or Affinity themselves.

Questions

How do I find the color palette of an image?

Drop the image on this page. Every visible pixel is counted, similar colors are grouped, and the main ones are listed with their hex codes, most common first. Set the number of colors with the slider and click the image to add any color the list missed.

How do I get a color palette from an image into Photoshop?

Make the palette here and download the .ase or .aco file. In Photoshop, choose Window > Swatches, open the Swatches panel menu, select Import Swatches and pick the file. Each color in the file is named after its hex code.

Why does a color I can see not appear in the palette?

Small areas lose to large ones. A color that covers a few pixels, like a highlight or an eye, can be merged into a nearby color. Raise the number of colors, or click that spot on the image to add the exact color.

Does it give the same palette every time?

Yes. The method has no random starting points, so the same image and the same number of colors always give the same palette, in the same order.

Which image files can I use?

Any image your browser can decode: PNG, JPG, WebP, GIF, BMP and AVIF in current browsers. iPhone HEIC photos open only in Safari; in other browsers, save the photo as JPG first. Procreate (.procreate) and Photoshop (.psd, .psb) files work too: the tool reads the artwork as one flat image and finds its colors. To keep the layers of a Procreate file, open it in the converter.

Are transparent pixels counted?

No. Pixels less than half opaque are skipped, so the empty background of a PNG cutout doesn't become a color in the palette.

How many colors can a Procreate palette hold?

30, according to palette makers and the open-source procreate-swatch-generator project; Procreate's handbook doesn't give a number. This tool stops at 30 colors so the .swatches file loads whole.

Is my image uploaded?

No. Your browser decodes the image and the colors are counted by the page itself. Nothing is sent to a server, which you can check in your browser's network panel.

Have a .procreate file to open?

Get a layered PSD in seconds. Previewing every layer is free, and the file never leaves your computer.