I was just trying to set PNG image avatar on some forum that had 80×80 avatar dimensions restriction and 6KB in physical size. And no matter what I tried in Paint.NET (which is my favorite daily image editor), the file was still too big. I just couldn’t get it below 7KB. Tried hammering it down into GIF which did the trick, but then also fine transparency went out the window, making it look really bad on the edges.
After this, I’ve tested countless other free programs, PngOptimizer, RIOT, IrfanView, XnView, GIMP, PhotoFiltre, PNGOut, AdvPNG and many other less known ones. Not a single one provided image quality and size that I’ve wanted. I did however find few exceptions that I’ve listed below.
I have also performed a size and visual inspection benchmark of several PNG optimization tools. You can read/view it by scrolling all the way down this page…
Best PNG optimizers
PNGQuant + PNGoo GUI (Standalone)
https://pngquant.org
Command-line tool with PNGoo graphical user interface (GUI). Full color control range from 256 colors down to just 2. Also has Dither setting and retains full alpha transparency across entire color selection range.
FileOptimizer (Standalone)
http://nikkhokkho.sourceforge.net/static.php?page=FileOptimizer
Program specialized in lossless file optimization of hundreds of file formats. One of them is also PNG. It provides lossless as well as lossy PNG optimization which is still near pixel perfect with drastic decrease in size and retained full alpha transparency.
Compress PNG (Online)
http://compresspng.com
Online lossy optimization with near pixel perfect image quality and full alpha transparency.
TinyPNG (Online)
https://tinypng.com
Online lossy optimization with near pixel perfect image quality and full alpha transparency.
OptimizePNG (Online)
http://www.optimizepng.com
Online lossy optimization with near pixel perfect image quality and full alpha transparency.
Comparison of PNG optimizers
Image comparison performed with RIOT using identical alignment and zoom level. All comparison screen captures saved with Paint.NET in lossless PNG image format at TrueColor 32bit depth.
Sample used (ORIGINAL) for testing is my sheep avatar, 80×80 PNG in TrueColor (32bit).
Verdict
After several hours of Googling for new programs and testing with some help of TechPowerUp community, I’ve found some darn good contestants. Most PNG optimizers are not particularly good because petty much all of them failed to decrease size below 7KB. Or they’ve all ruined edge alpha transparency when they did go the lossy route…
However, there were two exceptions (if I don’t count online optimizers and Adobe Photoshop because it’s not free), a free program named FileOptimizer and PNGQuant (with PNGoo GUI). They both provide spectacular lossy file size decrease while maintaining near pixel perfect quality and full alpha transparency. PNGQuant even goes a step further, providing full color control while retaining full alpha transparency. While PNGQuant’s 16 color sample above does exhibit some color artifacts, when you view avatar at 1:1 size, it is damn hard to notice it. And the file is tiny bit over 1KB in size. 1 KB!
Now there is not a single forum or webpage that will prevent you from using your avatar of choice due to avatar file size restrictions. Yay 🙂
Because this article is an ongoing research, it may be updated in the future.
Last update: 2016-01-21
Still I prefer an offline tool to accomplish that, got any good offline tool?
LikeLike
Unfortunately no. I’ve tried two (PNGOptimizer and OptiPNG) and they don’t make any notable difference. Weird.
LikeLiked by 1 person
I see, thanks.
LikeLike
I can see keeping it as 24/32-bit would be part of the problem.
It would be handy if you posted your before and after images, so people can compare any other optimisers.
I mostly use Irfanview, Gimp and RIOT with PNGOUT (also uses AdvPNG and OptiPNG)
When you swap optimisers in RIOT you can watch the preview zoomed in, so you can see any changes/compromises they make. It also allows fine control of what to do with the alpha layer.
Some size advantages could be the different colour remapping or using 7-zip deflate.
http://luci.criosweb.ro/riot/
http://advsys.net/ken/utils.htm
LikeLike
Thx for the effort, but I have to disappoint you. It’s just as rubbish as everything else standalone I’ve tried. Either it slashes away just few bytes and keeps image nice or it slashes away some kilobytes, but makes edges that meet transparency dreadfully ugly. But when I tossed the PNG into these online optimizers, they made the file half the size while retaining exactly the same transparency usage on the edges. That’s why I’ve said in original article how I have no clue what they are doing to achieve that, but it sure does work. Unlike these standalone apps…
I’ll update the article with comparison images so you’ll see what I mean. I’ll use RIOT for comparison, because I can nicely zoom all samples to the same level.
LikeLike