Optimise your images using Cloudflare Polish

Today I got the chance to try out a Cloudflare product, called “Polish“, and I must say it’s not bad at all.

What does Polish do?

  1. Dynamic image compression for both Lossless and Lossy mechanisms – Like a lot of tools out there, Polish offers dynamic compression of images using either Lossless or Lossy mechanisms; Lossless for NO change of quality and reduction is only from stripping image metadata vs Lossy for a reduction of bits in the image and so therefore a slight but negligible loss of quality. These are then cached the next time these images are requested. Pretty good but pretty standard so far.
  2. WebP support – Where it gets sweeter is the support for WebP compression. If you’re like me who haven’t heard of this format until recently, WebP is a modern format of images developed by Google which promises a significant 25-34% reduction of image size, compared to JPG and PNG. The format, however, is only currently supported by Google Chrome, Opera, and UC at the time of writing. The good news is that these browsers combined represent almost 75% of the web users these days (caniuse.com – 74.2% and THIS blog at 74.5%). Another good news is Safari and Firefox are experimenting with the format since it’s open-source.

Do I recommend it?

For the return on investment, yes I do. This would suit companies who want a quick and practical solution. It seriously is a 2-min job that fixes the problem for 75% of your end users. Need I say more? Ah yes, of course, you also need to pay that extra $20/month to be on a “Pro” plan which opens up to other Cloudflare products that will help boost your website performance like Mirage (targeting users on a slow internet connection) and RocketLoader (javascript boost).

Why don’t you give it a try?

If you’re not on Cloudflare yet, visit this tutorial first on how to setup your site on Cloudflare.

Once you’re on the Pro plan on Cloudflare, navigate to the Speed tab and enable the following:

Enable Cloudflare Polish with WebP

Once enabled, make sure to purge the cache by heading to the Caching tab > Purge Everything.

Give it a few minutes and test the WebP works by navigating to the Network tab on your browser and checking your images are served as WebP.

Serve Images as WebP

You will see right away your images will have been reduced.

I know this is not a perfect solution but for practical reasons, some clients are happy enough to go with this option considering the little effort it requires and the impact it has. It could or could not happen, but the rest of the browsers might eventually join the party.

%d bloggers like this: