More Site Speed Gains with Brotli Compression Algorithm

We are happy to announce that we have deployed and enabled by default the Brotli compression algorithm on our Site Tools servers so websites hosted there could get up to 15-20% speed gains from using it. 

What is Brotli?

Brotli is a next generation compression algorithm developed by Google as a successor to the popular gzip method that we’ve had running on our servers for ages. The idea is simple – once your application produces the HTML output of your website and the output is compressed together with all the resources it loads, the data is transmitted over the Internet and then the browser decompresses the content before rendering it. This process significantly reduces the size of data that’s been moved from the server to the visitor, resulting in speed gains multiple times bigger than the milliseconds lost for compression and decompression.

How much faster is Brotli compared to gzip?

The new algorithm provided by Brotli compresses the website into smaller data size, which makes it faster to transfer. JavaScript files compressed with Brotli are roughly 15% smaller than the ones compressed with gzip. HTML files are around 20% smaller and CSS files get around 16% size reduction. Those numbers of course will differ depending on your particular files.

Sign Up For
More Awesome Content!

Subscribe to receive our monthly newsletters with the latest helpful content and offers from SiteGround.

Thanks!

Please check your email to confirm your subscription.

A test with one of the WordPress’s default themes – TwentyTwenty shows that it produces a 19584 bytes of data uncompressed, 6003 bytes compressed with gzip and only 4863 bytes when compressed with Brotli! This means that you get more than 75% reduction in size from uncompressed content and 19.5% from gzip. 

How to use Brotli?

We have enabled Brotli on all our Site Tools servers and if your account is hosted on one of these, your site will automatically take advantage of it. You don’t have to do anything to get it! 🙂 Browsers that support Brotli compression, which are the majority of the browsers now, pass the appropriate “accept-encoding: br” header when performing the request and get the Brotli-compressed content. Older browsers that don’t support it will be served with gzip-compressed data. If you are still hosted on a cPanel server, don’t worry – we expect migrations to Site Tools to be completed by the end of March 2021 so you won’t have to wait long to get it as well.

author avatar
Hristo Pandjarov

WordPress Initiatives Manager

Enthusiastic about all Open Source applications you can think of, but mostly about WordPress. Add a pinch of love for web design, new technologies, search engine optimisation and you are pretty much there!

Speed

Comments ( 27 )

author avatar

dr.newdell2015@gmail.com

Jan 15, 2021

Many thanks! The article is well written. The service is very much appreciated. In that we don't have to do anything, we can all be thankful to you for this excellent upgrade. SN

Reply
author avatar

david marsh

Jan 17, 2021

Its great to know that you guys are contently improving the platform. Its also great when these types of improvements are made without us having to do anything. Much appreciated. Thanks.

Reply
author avatar

Krunoslav

Jan 18, 2021

Hello! I plan to become a new SG customer and have few very short questions. As I have read here, there is a server side caching. That is off course great news. So do I need to install any cache plugin at all if the server side caching is available? And if I decide to install a cache plugin can I choose some other plugin (for example WP Rocket), or it has to be SG Optimizer plugin? And finally, on my existing site which I plan to transfer to SG I use premium Cloudflare service (not free version). I would like to continue to use that also, but I wonder if there is going to be some conflict between those 3 things since they are all doing the same thing. For example I can enable Brotli Compression by Cloudfare, by plugin, and it's already enabled from the server side. So should I use just one of those 3 things for the same thing (brotli Compression, for example) or it's ok to use both plugin and Cloudflare for the same thing. The same applies for other things such as auto minify java script, css, html etc. Thank you very much on your answer.

Reply
author avatar

Hristo Pandjarov Siteground Team

Jan 19, 2021

You need to use the SG Optimizer plugin in order to get the best loading speeds for your site and utilise our server-side caching. Since it provides all the necessary front-end and media optimizations too, you do not need to use an other plugin like WP Rocket for example. Now, if you have full-page caching on Cloudflare you can keep the Dynamic caching off at SG Optimizer in order to avoid potential caching issues. Same goes for front end optimizations - do them at SGO or at the Cloudflare plugin, just don't duplicate functionality.

Reply
author avatar

MiamiCityMan

Feb 02, 2021

Just to be clear: no futher internal caching plugin should be used if full CLOUDFLARE caching is activated?

Reply
author avatar

Hristo Pandjarov Siteground Team

Feb 03, 2021

Yes, you don't need anything else

Reply
author avatar

Patrick Bianconi

Feb 26, 2021

Thanks for the CloudFlare Full Page tip.. I will have to check.

Reply
author avatar

Lazhar

Jan 21, 2021

Noticed a speed improvement over the last week or so. Probably due to Brotli compression as nothing else changed. Thank you for constantly improving the service behind the scenes!

Reply
author avatar

Kris

Jan 27, 2021

Hi Hristo, This is so great news for me that Brotli is now implemented on SG. I remembered that late 2018-2019 I have ever recommended you about Brotli compression algorithm. So now I couldn't wait enjoying it and awaiting migration to Site tool :) Totally appreciated SG Hosting Service since 2016 on GoGeek plan.

Reply
author avatar

Hristo Pandjarov Siteground Team

Jan 28, 2021

I hope that we will migrate everyone to Site Tools by the end of march so you will soon be able to benefit from it :) Once we completely move awawy from cPanel our hands will be untied to implement new technology much, much faster!

Reply
author avatar

Jerry

Jan 31, 2021

Good news on Brotli. Even better news is the end of March date to complete the migrations to Site Tools! Been waiting for that for quite a while :-)

Reply
author avatar

LM

Feb 08, 2021

Hello, we have a Cloudflare account that all our SiteGround sites are added to. For each site, we already had the 'Brotli' option enabled from within our Cloudflare account. So we want to ask if there is any potential issue with having Brotli now enabled in both SiteGround and Cloudflare? If there is, is it best to have it enabled just in SiteGround or just in Cloudflare? If it is best to have it enabled just in Cloudflare, is there any way we can have it disabled for all our sites in SiteGround? We're not sure where this option could be located in our account. Thank you.

Reply
author avatar

Hristo Pandjarov Siteground Team

Feb 08, 2021

There isn't any issue, since you have Cloudflare being "man in the middle" it will only optimze the connection between the server and the CF end point. If you're using CF it is best to have the full page caching working there otherwise you're slowing your site down probably. Brotli on or off won't have signifficant effect compared to that.

Reply
author avatar

LM

Feb 11, 2021

Okay, wonderful. Thank you for answering our questions about this!

Reply
author avatar

Minu

Feb 13, 2021

Is it available on google cloud hosting?

Reply
author avatar

Hristo Pandjarov Siteground Team

Feb 15, 2021

All our accounts are on GCP and they hahve it available :)

Reply
author avatar

WebKiwiNZ

Feb 16, 2021

What is the decompression time like is the algorithm compared to gzip? It is good to improve network performance but what is the impact on cpu utilisation at the users end? On older hardware that would have a significant impact if it has a much higher workload to decompress.

Reply
author avatar

Hristo Pandjarov Siteground Team

Feb 16, 2021

Savings in networking traffic dramatically outweight the time needed for compression and decompression. However, they are better than the gzip ones too.

Reply
author avatar

Patrick Bianconi

Feb 26, 2021

Thank you for this. SG constantly improving and keeping costs at a minimum.

Reply
author avatar

Scott P

Feb 26, 2021

Is there a browser-side way to test if it's in operation?

Reply
author avatar

Hristo Pandjarov Siteground Team

Mar 01, 2021

Yes, you can used the right click -> inspect element and check the Networking tab -> headers for your site. Refresh and if the browsers supports Brotli, you should see a response header: Content-Encoding: br

Reply
author avatar

Judy Burns

Feb 28, 2021

Thank you so much for all the work you do to make SG a great hosting company.

Reply
author avatar

Tim Krueger

Mar 02, 2021

Just wanted to say a big thank you. The moves you've made since I switched all my sites to sitegeound a little over 3 years ago are greatly appreciated.

Reply
author avatar

ts1g

Mar 03, 2021

Submitted this as a comment back on February 6, and got a confirmation that it had been received / was waiting for moderation, but it never posted: "Brotli compression is great, and much needed, but equally needed is for SG to upgrade from Postgresql 11.8 to Postgresql 12.x or 13.x since no version of 11 supports calculated fields (generated columns in Postgres speak). The combination of Brotli and stored calculations would significantly bump throughput from Postgres databases, and Postgresql 12 has been supported on Google Cloud for some time now.

Reply
author avatar

Hristo Pandjarov Siteground Team

Mar 08, 2021

The upgrade is in our roadmap but at this point I can't give you an ETA when exactly it will be performed. We will do it as soon as possible.

Reply
author avatar

Chris Bennett

May 10, 2021

I love the idea of automating Brotli with Gzip fallback for all customers. The less manual htaccess needed, the better. However, I noticed that .ico and .webmanifest files don't appear to be compressed. It seems, very likely due to the new-ish automated compression, that htaccess can't do anything. Attempts to add htaccess compression rules in the "old" way seems to result only in additional and unnecessary Vary: accept-encoding headers being added and only on the files which are already successfully compressed. Is there any chance .ico and .webmanifest files could be added to the compression?

Reply
author avatar

Hristo Pandjarov Siteground Team

May 13, 2021

Those are not mime types that we compress by default. It doesn't make much sense to do so since those are very, very small files and the difference will be insignifficant anyway.

Reply

Start discussion