Using only brotli compression

How can I enable only one compression that is BROTLI , I'm using ubuntu 20.04 already installed LSWS with php 8.1 and using wordpress, by default it will be GZIP compression but I want the default compression to be BROTLI. thank you


Well-Known Member
brotli cannot be used with static sources such as CSS, JS, images, .... Brotli content encoding only works with dynamically generated sources such as the main document. So that brotli can be used at all, the corresponding function must be activated in the LiteSpeed webserver configuration. But if you use ESI, then brotli cannot be used in this case either. You should therefore first contact your hosting provider to see whether he has activated brotli.

btw. the port used doesn't matter for brotli


Well-Known Member
are you enable brotli compession in settings?

X-Litespeed-Cache: hit - saved lscache

like says developers:
- by default lscache files saved in gzip enconding
- only when client always several times send request with only brotli encoding support then lscache saved in brotli encoding

or you must run crawler to generate cache only with brotli enconding support
Last edited:


Well-Known Member
Yes, but you don't take the second step before the first. If you don't know where and how to activate brotli in the LSWS, you don't have to explain what this has to do with caching. Especially since the cache initially has nothing to do with brotli.


Well-Known Member
I'm sure that brotli already enabled.
And I am the good Lord who knows that it will rain in 4 weeks from today. ;)

and for uncached pages with "X-Litespeed-Cache: miss" encoding is br
Where did you read that? We all know that you can't use a brotli. So how do you want to know something again that you don't have?! Brotli has nothing to do with the cache or the status of the cache. How do I know? I use brotli and for static sources as well.


Well-Known Member
First you have to check whether brotli is activated in the configuration of the LiteSpeed web server. As long as this has not been checked, you do not need to post any pictures. Also, a link to your site would be good.