Image compression

PNG Compressor

Choose lossless optimization or fewer colors while keeping PNG transparency.

Images are processed entirely in your browser and are never uploaded to a server.

or drag and drop one image here

Input: static PNG. Animated PNG is not supported.
Lossless optimization preserves pixel colors. Color reduction may change colors; transparency is preserved.
This tool always outputs PNG.

PNG uses lossless saving and has no quality percentage.

Original Preview

Choose an image to see the original

Result Preview

Apply changes to see the result

Each image can be up to 100 MiB. Files over 50 MiB trigger a high-memory-use notice. Original and output images are limited to 16 megapixels and 16,384 pixels per side. PNG lossless optimization supports up to 16 megapixels; color reduction supports up to 8 megapixels. Resize larger images first.

About This Tool

PNG Compressor works with transparent icons, screenshots, and other PNG images. Lossless optimization preserves pixel colors and transparency. To try for a smaller file, allow color reduction and check the changes before downloading.

How to Use

  1. Choose a PNG image and check its original size and transparent areas.
  2. Try “Lossless optimization” first. If color changes are acceptable, choose “Reduce colors” and set the number of colors.
  3. Click “Compress PNG” and check the output size, gradients, and semitransparent edges.
  4. If the result is larger, try fewer colors or another format. Download the PNG when you are satisfied.

Settings explained

  • Lossless optimization preserves the original colors and transparency while trying to reduce file size.
  • Reduce colors: choose 256, 128, 64, or 32 colors. This may change gradients, photo colors, and semitransparent edges.

Supported Formats

  • Input: static PNG. Animated PNG is not supported.
  • Output: PNG, preserving pixel dimensions and transparency.

Image Processing Notes

Changes apply to the full original image and keep its loaded pixel width and height by default. The preview may appear smaller; the downloaded file contains the full processed image.

Each image can be up to 100 MiB. Files over 50 MiB trigger a high-memory-use notice. Original and output images are limited to 16 megapixels and 16,384 pixels per side. PNG lossless optimization supports up to 16 megapixels; color reduction supports up to 8 megapixels. Resize larger images first.

Compression and image quality

  • PNG does not use a JPG-style quality slider. Lossless optimization and color reduction are separate choices; reducing colors is a lossy change.
  • A well-optimized PNG may have little room for improvement. Even a lossless result can be larger than the original.
  • Reducing colors in a photographic PNG can cause banding. Icons and images with fewer colors are often better candidates.
  • Both modes support transparency. Pay particular attention to semitransparent edges and gradients.
  • If the file is still too large, try fewer colors or use PNG → WebP.
  • Downloads contain the full processed image. Saving again can change file size and compression details, and usually removes original EXIF, GPS, and similar information. Keep your original file.

Privacy

Images are processed entirely in your browser and are never uploaded to a server.

Files are not saved automatically. Download any results you want to keep before clearing or leaving the page, and keep your original file.

FAQ

Is PNG a lossless format?

PNG can store pixels without loss. “Lossless optimization” preserves colors and transparency. “Reduce colors” changes colors before saving, so it is a lossy reduction.

Why might PNG compression make little difference?

The original may already be optimized, and colors and textures affect how much it can shrink. The result is not guaranteed to be smaller.

Does reducing the number of colors affect quality?

It can. Fewer colors make banding and color changes more likely in gradients and photos. Compare the preview before downloading.

Will the transparent background be preserved?

Transparency is preserved in both modes. Color reduction may change the colors of semitransparent edges, so inspect the result.

Back to the Developer Tools Directory