This is an old revision of the document!


Brotli compression for dynamic responses and automatic GZIP and BROTLI conversion for cached pages

LSWS has added brotli compression support for a while, but it used to be for static files only. Starting with LSWS 5.3, Brotli compression for dynamic responses has been added. Also, LSWS will do automatic GZIP and BROTLI conversion for cached pages.

To test brotli compression, the client (browser) must be Brotli compatible. Google Chrome: Chrome 49+ and Mozilla Firefox: Firefox 44+ are good for brotli testing. Also, you will need to run test over an HTTPS connection, can not be a HTTP connection.

The following page header shows “Content-Encoding:gzip”, since it is only HTTP connection for the same domain.

When we test HTTPS connection for the same domain, the header shows “Content-Encoding:br”.

You should test a page without ESI on it, such as a https wordpress page as indicated as above. LSWS will use brotli compression as default instead of gzip as far as client supports it(make sure to test HTTPS connection instead of HTTP). However, for ESI pages, gzip compression will be used since LiteSpeed cached ESI pages are optimized for gzip, such as a Magento page.

  • Admin
  • Last modified: 2018/08/17 18:43
  • by Jackson Zhang