![]() |
|
oxipng --strip all input.png -o better.png Let’s test a typical 2.4 MB screenshot saved from Chrome (PNG).
Introduction: Why "PNG to PNG Better" Matters If you’ve ever searched for "PNG to PNG better," you’re not looking for a format conversion. You already have a PNG. What you want is a better PNG—smaller file size, higher visual quality, cleaner transparency, or improved compression. Unlike converting PNG to JPG or WebP, staying within the PNG format allows you to preserve lossless quality while still making drastic improvements. png to png better
❌ ✅ Dangerous: JPG artifacts become permanent. Never re-encode JPG to PNG for size. oxipng --strip all input
The "better" PNG was yet indistinguishable to the naked eye. Part 8: Workflow Integration – Making It Automatic To consistently produce better PNGs from PNGs, integrate optimization into your pipeline: For Web Developers (npm scripts) npm install -g imagemin-cli imagemin input.png --out-dir=output --plugin=pngquant For GitHub Actions / CI Use calibreapp/image-actions to auto-optimize PNGs on pull requests. For Designers (Export Presets) In Photoshop: File > Export > Save for Web (Legacy) → PNG‑24 with "transparency" and "convert to sRGB" unchecked for smaller files. Part 9: Common Myths About PNG Optimization ❌ "PNG can't be compressed without quality loss." ✅ False: Lossless compression exists. Visually lossless is also possible. What you want is a better PNG—smaller file
pngcrush -rem alla -rem text input.png better.png Using Oxipng :
| Process | File Size | Quality | |---------|-----------|---------| | Original PNG | 2.4 MB | Baseline | | Oxipng -o 4 | 1.9 MB | Lossless (identical) | | pngquant (256 colors) | 412 KB | Visually lossless | | Strip metadata + zTXt | 1.7 MB | Lossless | | + Remove alpha channel | 1.4 MB | Lossless |