2026-03-24
Compress a PNG to an exact target size
PNG is lossless. The encoder can try harder at deflate compression, but it cannot throw away detail the way JPEG does. A screenshot full of flat color may already be small. A PNG exported from a photo is often larger than the JPEG it came from. There is no quality number that will walk a photo-PNG down to 50 KB while keeping every pixel.
What Auto mode does
KBPass’s default output is Auto:
- JPEG stays JPEG
- WebP stays WebP
- PNG is re-encoded as WebP, and the result card says so
WebP has a quality control, so the same binary search used for JPEG can hit a real budget. If WebP encoding fails in an old browser, the file falls back to JPEG and that is also labeled.
If the PNG is already under the target and you did not set max dimensions, the original PNG is returned untouched.
When you must keep a PNG
Choose PNG resize. The tool will only change width and height until the lossless file fits, or until it reaches a small minimum and reports that the target was missed. Charts and UI screenshots with large flat areas often survive this. Photographs usually do not, unless you allow a much bigger budget.
A practical choice
| Need | Choice |
|---|---|
| A form only checks file size | Auto (PNG becomes WebP) |
The form requires .jpg | JPEG |
| The form requires a true PNG | PNG resize, and expect a smaller picture |
Try it on the compressor. Read the notice on the result before you rename the file back to .png. A WebP renamed to .png will fail the next upload.