Color Palette Extractor
Pull the dominant colors out of any image as a usable palette.
Updated · Examples checked by automated tests
Drop an image to extract its palette
Pixels are sampled on a canvas in your browser
About Color Palette Extractor
Building a colour scheme around a photograph, a product shot or a logo is far easier when you can see the actual colours it contains rather than eyedropping by hand.
This extractor samples your image on a canvas, quantises the pixels and returns the most representative colours with their share of the image, ready to copy as hex, RGB, HSL or CSS variables.
How Color Palette Extractor works in your browser
The image is drawn onto a canvas and its pixels read back. Colours are quantised into buckets and the most populated buckets become the palette, each reported with its share of the image.
Frequency-based extraction favours large areas of colour, so small bright accents can rank low; increasing the palette size usually surfaces them. Swatches copy as hex, RGB or HSL, or the whole palette as CSS custom properties.
When to use it
- Building a colour scheme from a photograph or product shot.
- Pulling brand colours out of a logo you only have as an image.
- Generating CSS variables to match an illustration.
Worked examples
Two dominant colours
Settings: Palette size 8
Input
An image that is three-quarters navy #1e3a8a and one quarter amber #fbbf24Expected output
#1e3a8a: 75%
#fbbf24: 25%Each swatch carries its share of the image. Only colours that are actually present are returned, so asking for 8 can give fewer.
Near-identical shades are grouped
Settings: Palette size 8
Input
An image split between #ff0000 and #fe0101Expected output
#ff0101: 100%Colours a viewer cannot tell apart are merged into one swatch, so JPEG noise does not fill the palette with duplicates.
Limits and checks before you use the result
- Images are downscaled to 400 px before sampling, so tiny details may not appear.
- Transparent pixels are ignored.
- The palette is based on pixel counts, not on what draws the eye; a small bright logo can be missed in a large photo.
Frequently asked questions
How are the colors chosen?
Pixels are quantised into buckets and the most populated buckets are returned, which approximates the colors a person would name when looking at the image.
Why are some colors missing?
Small but striking accents occupy few pixels, so they rank low by frequency. Increasing the palette size usually surfaces them.
Can I export the palette?
Yes - copy any swatch as hex, RGB or HSL, or export the whole palette as CSS custom properties.
Related tools
Favicon Generator
Generate every favicon size from a single image, plus the HTML.
QR Code Generator
Create QR codes for links, Wi-Fi, contacts and text, then download PNG or SVG.
Image Compressor
Shrink JPG, PNG and WebP files without leaving your browser.
Image Resizer
Resize images to exact dimensions or by percentage, offline.
Crop Image
Crop images to a selection or a fixed aspect ratio.
Image Converter
Convert between JPG, PNG and WebP directly in the browser.