PNG is always lossless, and that is the first thing you need to understand. A PNG file is already compressed with DEFLATE, the same algorithm that makes a ZIP file, and no other image format gives you that guarantee of exact pixels. The real question of when not to compress png is about recognizing the moment any additional change costs more than it saves. Keep your originals untouched. Never run palette reduction on a master file. Never send a compressed copy to print. Never compress a file someone else will edit. And never re-compress an image that has already been palette reduced unless you are prepared to lose quality permanently.
Should I Compress Master Files?
The answer is no. If you are asking should i compress master files, the answer is keep them untouched. A master file is your source of truth. It is the highest quality version you have. Palette reduction cannot be undone. Once you drop from millions of colours to 256 or 128 or 64, those near identical shades are gone. You cannot get them back. Lossless optimisation is safe to run on a master, but it saves only 5 to 15 per cent on a typical image. The real savings come from reducing colours, and that is exactly the step you must skip on a master file.
Can You Compress PNG for Print?
Do not compress PNG for print. Print resolution is far higher than screen. A monitor hides banding that a glossy magazine page exposes clearly. Palette reduction collapses thousands of near identical shades into one palette entry. That creates exactly the kind of flat colour band that looks like a rendering error on paper. Your print provider expects the full colour depth of the original image. Send them the untouched file. If the file is too large to upload, resize the pixel dimensions first, but never reduce the colour palette. A soft gradient printed at 300 DPI needs every one of its original shades to look continuous.
Does Compressing PNG Lose Data?
Yes and no. Lossless optimisation does not lose data. The decoded pixels are identical to the original. Palette reduction does lose data. It rebuilds the image from an adaptive palette of typically 256, 128, or 64 colours. Each pixel needs 7 or 8 bits instead of 24 or 32. Thousands of near identical shades collapse into one entry. That is permanent data loss. The visible failure mode is banding in smooth gradients. The second failure mode is a stair step fringe on semi transparent edges. A soft alpha band around a rounded logo needs enough palette entries. When it snaps into discrete steps, the edge looks jagged. Curves and diagonals are the worst offenders. A gentler setting with more colours fixes it, but the data is still gone. So does compressing PNG lose data? Only if you choose a lossy method. Lossless methods preserve every pixel exactly.
When to Leave a PNG Alone
Leave a PNG alone if it is already optimized. A correct lossless tool returns the original file if re encoding would make it larger. If the file size did not change, you are done. Leave a PNG alone if someone else will edit it. They need the full colour depth to work with. A palette reduced file forces them to start from a degraded source. Leave a PNG alone if it is a photo. A photo stored as PNG is roughly ten times the size of the same photo as JPEG at a quality difference invisible at normal viewing distance. The honest solution is to change format, not to compress the PNG. JPEG discards high frequency detail the eye is poor at noticing. PNG promises exact pixels, so it can never do that. Converting a transparent PNG to JPEG flattens transparency onto a solid colour, usually white. If you need transparency, use WebP. Google's published figure for WebP lossless is about 26 per cent smaller than PNG. WebP is supported by all current browsers.
What Palette Reduction Means for Your Files
Palette reduction rebuilds the image from an adaptive palette of a fixed number of colours. The typical maximum is 256. You can go lower: 128, 64, 32, even 2. Each step halves the number of colours and increases the risk of visible banding. The savings are real. A screenshot can drop by 70 to 85 per cent. A logo by 60 to 80 per cent. A chart or diagram by 70 to 80 per cent. An illustration with gradients by 40 to 65 per cent. A photograph stored as PNG by 40 to 70 per cent. But the cost is permanent. The visible failure mode is banding in smooth gradients. A soft fade needs many closely spaced colours to look continuous. When those colours collapse into one entry, the gradient becomes a set of flat bands. The second failure mode is a stair step fringe on semi transparent edges. The soft alpha band around a rounded logo needs enough palette entries. When it snaps into discrete steps, the edge looks jagged on curves and diagonals. A gentler setting with more colours fixes it, but the data is still gone. There is no undo for palette reduction.
Typical Savings by Image Type
| Image Type | Lossless Optimisation | Palette Reduction |
|---|---|---|
| UI Screenshot | 5 15% | 70 85% |
| Logo, Icon, Line Art | 5 15% | 60 80% |
| Chart or Diagram | 5 15% | 70 80% |
| Illustration with Gradients | 5 15% | 40 65% |
| Photograph as PNG | 0 5% | 40 70% |
| Already Optimised PNG | 0% | 0% |