PNG compressor
Nothing is uploaded; every file is processed in this browser
PNG stores every pixel exactly, so there is no quality to turn down and no detail to discard. A PNG gets smaller in three ways only: fewer pixels, fewer colours, or a format that is allowed to throw something away. This page does the first and the third.
How to compress a PNG
Nothing in PNG is thrown away, and knowing how it compresses explains why some files barely move. Each row of pixels is first run through one of five filters — None, Sub, Up, Average, Paeth — which rewrite each byte as a difference from its neighbour to the left or above, and the filtered rows then go through the same DEFLATE algorithm ZIP uses. That makes the file size a function of how repetitive the image is, not of how it looks. A screenshot of flat interface colour compresses enormously because whole rows become runs of zeroes. A photograph is noisy at the pixel level, so almost nothing predicts anything and the file stays close to its raw size.
What a dedicated PNG optimiser does that a browser cannot
Tools like pngquant do not compress harder; they quantise. Twenty-four-bit truecolour becomes a 256-entry palette, and the image goes from three or four bytes a pixel to one, which typically takes 60–70% off a screenshot with no difference you can see. That is a lossy step performed on a lossless format, and it is the reason a command-line optimiser beats anything a web page can do. A browser cannot reach it: a canvas hands back 8-bit RGBA and its PNG encoder writes truecolour with an alpha channel, with no way to ask for a palette or to choose the filters.
This has a consequence worth knowing before you use any in-browser PNG tool. An already-optimised PNG-8 re-encoded through a canvas comes back as 32-bit RGBA and is frequently larger than it went in. If a file has been through pngquant or an export preset that quantised it, leave it alone — resizing it is still safe, re-encoding it at the same size is not.
When the answer is that it should not be a PNG
A photograph saved as PNG is typically five to ten times the size of the same image as a good JPEG, with nothing gained. The alpha channel is the other quiet cost: a fully opaque image saved as PNG-32 carries a fourth byte per pixel that is 255 everywhere, and DEFLATE compresses that run away to almost nothing, so it is cheaper than it sounds — but it is still a channel being stored for no reason. If the picture is photographic and has no transparency, the conversion is the compression.
What people use it for
- Halving a screenshot taken on a 2× display before it goes in a document
- Converting a photograph that was mistakenly exported as PNG
- Getting a transparent logo down to a size an email signature will accept
- Cutting a folder of exported UI assets down before they are committed
- Deciding whether a file has any business being a PNG at all
Questions
Because PNG is lossless: filtering plus DEFLATE, with nothing discarded. Quality only applies once you switch the output to WebP or JPEG.
It was probably a palette PNG-8. A browser canvas re-encodes as 32-bit RGBA, which is more bytes per pixel than a palette. Resize such a file rather than re-encoding it.
It quantises the image to 256 colours, which is a lossy step, and drops it to one byte a pixel. No browser API exposes palette encoding, so a web page cannot do it.
Cap its dimensions, or convert it to WebP, which supports transparency and is usually far smaller at the same size.
Yes. It is the natural replacement for PNG where transparency matters and file size does too.
Retina capture. A 2× display records twice the pixels in each direction, so four times the data, for an image that will be viewed at its CSS size.
No. Everything runs in your browser, so there is no upload and no queue.