Image Color Palette Generator
Generate a palette from an image.
About this tool
Choose an image and a palette size. You get a list of the main colours with hex, RGB and percentage coverage, skipping near-duplicates so the palette is varied.
How to use
How it works
The image is shrunk to 64 x 64, colours are grouped into coarse buckets, and the most common groups become the palette. Colours that look almost the same are merged. Transparent pixels are ignored.
Worked example
Red and blue flag
- Input
- Half red, half blue image, 2 colors
- Output
- #ff0000 50%, #0000ff 50%
- Walkthrough
- Each half fills one bucket.
Limitations
- Sampled from a small copy, so tiny details are missed.
- Percentages are approximate.
- Not perceptually clustered.
Questions
How many colors can I get?
Are percentages exact?
What about one dominant color?
Is it uploaded?
Features
- Multiple colors
- Hex and RGB
- Coverage share
- Runs in your browser
Related resources
Guides and videos from around the web—opens on YouTube or the publisher’s site.
How are Images Compressed? JPEG In Depth
Branch Education
JPEG mechanics behind smaller web and social exports.
Watch on YouTubeResponsive images - PWA Training
Chrome for Developers
How image weight affects real-device performance.
Watch on YouTube
- Image file type and format guide
MDN
JPEG, PNG, WebP, AVIF tradeoffs for convert and compress tools.
- Efficiently encode images
Chrome Developers
Lighthouse image budgets that motivate compress tools.