Palette
Runs in your browser

Colour palette from an image

Drop a photo and get its dominant colours as hex codes and CSS variables, with the share of the image each one covers.

Drop a photoor click to choose — colours are extracted on your device

Questions

How are the colours chosen?

The image is scaled to about 220 px, transparent pixels are dropped, and the remaining pixels are grouped with k-means clustering. Cluster size becomes the percentage shown on each swatch.

Why does it differ from Photoshop?

Different sampling and clustering means slightly different shades. For brand work, treat these as a starting point and adjust by eye.

What can I do with the percentages?

They tell you which colour carries the image. The largest cluster is usually the right background or primary colour; small ones are accents.

Is the image uploaded?

No. Pixels are read with getImageData in this tab.

Other pages

Image colour pickerPull the real colours out of a screenshot, a logo or a photo and copy them as hex values for your design tool. Extract colours from a photoUseful for matching a website to a product shot, or finding a palette for an illustration that has to sit next to a photo.