Skip to content

Latest commit

 

History

31 Commits

Folders and files

Repository files navigation

Img2Palette Logo
Img2Palette

A browser-based tool for extracting color palettes from images. Runs client-side with no external dependencies, supporting custom palette sizes, color sorting, swatch editing, and multi-format export.

Original Extracted Palette
Original → Extracted Palette


Quick Start

1. GitHub Pages (Online)

Use the hosted version directly in your browser here.

2. Standalone (Offline)

Download Img2Palette.html from the repository root and open it in any browser.

3. From Source

git clone https://github.com/meangrinch/Img2Palette.git
cd Img2Palette
python scripts/build.py

Features

  • Extraction: Extract up to 256 colors (never more than the image holds) from images with Wu, K-Means++, or Median Cut, preserving small accent colors
  • Sorting: Order palettes into smooth color gradients while preserving locked swatches
  • Organization: Arrange swatches by hue spectrum or lightness with separated neutral tones
  • Swatch Editor: Click to copy hex codes, lock favorite colors, edit or remove swatches, and sample new ones with the eyedropper
  • Preview: Compare the image and palette with a side-by-side view, palette-only view, eyedropper loupe, pixel grid overlay, and up to 3200% zoom, with touch panning and pinch-zoom on phones and tablets
  • Export: Save as PNG swatches (strip, grid, or preview layout, with optional hex labels), JSON, GPL, CSS variables, or hex lists, or copy to the clipboard

Support the Project

Img2Palette is open-source and free. If it saves you time or enhances your workflow, consider supporting its development!

Support on Ko-fi


License & Credits