kornelski/pngquant
FreeLossy PNG compressor — pngquant command based on libimagequant library
About kornelski/pngquant
pngquant is a lossy PNG compression tool that dramatically reduces file sizes by converting 24/32-bit PNG images to efficient 8-bit PNG format with alpha channel, often achieving 60-80% smaller files. The compressed images remain fully standards-compliant and are supported by all web browsers and operating systems. pngquant features high-quality palette generation using advanced quantization with gamma correction and premultiplied alpha, along with a unique dithering algorithm that avoids adding unnecessary noise. It includes a configurable quality level (similar to JPEG) that automatically determines the required number of colors and can skip images that cannot meet the desired quality. The tool is fast and modern, built on the portable libimagequant library with multicore support via OpenMP and Intel SSE optimizations. This is the official pngquant repository, and the compression engine is also available as an embeddable library.
Key Features
Pros & Cons
- Significant file size reduction (60-80% smaller than standard 24/32-bit PNG)
- High-quality output with advanced quantization and dithering algorithms
- Fully standards-compliant and universally supported across browsers and OS
- Fast processing with multicore and SSE optimizations
- Open source and free to use with no restrictions
- Configurable quality levels to balance size and visual fidelity
- Lossy compression introduces some data loss and may not suit all use cases
- Command-line interface only, no graphical user interface included
- Limited to 8-bit color palette (256 colors max per image)
- Not ideal for images requiring full 24-bit color depth or lossless preservation