Best online JPEG image compressors for web in 2018

Although a number of lists of compressors are available on the Internet, they seem to be a bit outdated and do not reflect well the state of the art. A proper and updated benchmarking on performance based on clear and objective metrics is missing.

For the last 25 years, JPEG has remained the most extended image compression standard on web. JPEG is lossy, which means it discards information to reduce file size. The amount of information discarded is controlled by different settings, the best known being the quality level.

Since every image is different, the same compression settings (i.e. quality level) may produce very different results in different images, requiring an specific adjustment to balance between size and actual perceived quality for every image.

In order to get the smallest file size without hurting perceived visual quality, a content-based approach needs to be adopted to adjust the compression parameters in function of each image content. In a blind fixed-settings approach, many images will be under-compressed or they will have the visual quality damaged.


In this comparison, we focus on three image optimizers that claim to implement a content-based approach to image compression: TinyJPG, Kraken, and Abraia. We also extend the comparison to CompressJPEG since at the time of this benchmark it ranks as the online compressor with the highest traffic.

Examples from the image product dataset

Our comparison effort builds on a public image compression benchmark with 105 product images from E-commerce, designed to compare the performance of different implementations of the JPEG standard. We measure the overall file size savings, checking that visual quality remains untouched and no visible artifacts appear.

The image compressors

1. Abraia

Abraia compressor is a new tool that runs on an own-developed algorithm based on perception models and metrics capable to drive different image optimization operations (from smart cropping to adaptive watermarking to compression).

Abraia online web compressor screenshot

2. Kraken.io

Kraken is a recognized image compression service that claims to rely on image content to determine the compression settings applied. The good results that make it to the second position in the benchmark prove the claim.

Kraken web interface screenshot

3. TinyJPG

It is served by Voormedia and their recent research in the quest of features related to image content and capable to control the compression process seems to have been fruitful. It has gained a deserved good reputation in the task of deploying clean image optimization workflows.

TinyJPG online application screenshot

4. CompressJPEG

It is a simple online compressor with high traffic, the highest indeed according to metrics reported by SEMrush. Despite their default settings (quality level is set to 60), when assessed in terms of file size savings, it is far from its content-based contenders.

CompressJPEG screenshot

Performance comparison

The dataset used consists of 101 images that make 10.3MB in total. From the original 105 images, we discarded 4 that weighted over 1 MB, exceeding the limit of the free option of Kraken.

Abraia achieves the highest reduction in file size with an average 64% less, to a final 4MB for the whole dataset. Kraken removes 59% from average file size to a final 4.6MB and TinyJPG takes a 58% of average file size to a final 4.7MB. CompressJPEG only achieves a 5.5MB final total size.

The following chart shows the compression achieved image by image for some of them.

Images size compression comparative side by side

Looking at the chart, it becomes clear that the three compressors are following different content-based approaches to drive compression. The difference is not about setting a higher or lower compression level but about determining the optimum parameters for each image. This optimum is one at which visual quality remains as in the original image while file size is reduced the most.

You can find the code and results for this comparison in https://github.com/abraia/benchmarking.

Summary

Content-based image compression relying on visual perception models and metrics brings big gains in terms of file savings and served visual quality.

The highest traffic happens to go to CompressJPEG, which behaves like a fixed-settings approach. This fact reveals a lack of awareness and calls for objective and transparent benchmarks that shed light on real performance.

If you take a look at most real websites, and re-compress some of their images with these content-based tools you will find that there is still a significant margin to reduce image weight without any additional damage to visual quality. All of this only shows that most extended image optimization workflows can be largely improved. And so the performance of websites with the associated benefits on SEO ranking, user experience, and conversion.