In order to do this I put code to .htaccess:

<ifModule mod_gzip.c>
mod_gzip_on Yes
mod_gzip_dechunk Yes
mod_gzip_item_include file .(html?|txt|css|js|php|pl)$
mod_gzip_item_include handler ^cgi-script$
mod_gzip_item_include mime ^text/.*
mod_gzip_item_include mime ^application/x-javascript.*
mod_gzip_item_exclude mime ^image/.*
mod_gzip_item_exclude rspheader ^Content-Encoding:.*gzip.*

But gmetrix show same issues with livesupporti files

enter image description here

How can I deal with this. And seometrix show that gzip don't work, can anyone explain me why? enter image description here

  • 1
    That mod_gzip compression configuration looks pretty good. My first guess is that mod_gzip isn't installed or enabled. Have you tried looking to see if the module is available and enabled? Nov 21 '17 at 18:24
  • phpinfo show that gzip is enabled.
    – pawelwaw
    Nov 21 '17 at 18:32
  • Try removing the <IfModule> wrapper - any error? mod_deflate is generally easier to use, more current and more likely to be installed.
    – DocRoot
    Nov 21 '17 at 18:39
  • it dosn't matter whether I use deflate or gzip. The question is can I gzip resources which are not on my server, but on another server, e.g. on server livesupporti.
    – pawelwaw
    Nov 21 '17 at 18:53
  • 2
    "gzip resources which are not on my server" - you should have added that information to your question, so we didn't waste time trying to debug your code/server config. (Your server can't influence the HTTP response from another server that you don't control!)
    – DocRoot
    Nov 21 '17 at 19:54

You have no control on expires, compression or any other header property on external resources.

Rather than trying to satisfy pointless speed score websites you should focus on how quickly your pages load. Google, Bing and your users DO NOT CARE what your code looks like or how your website loads the code, what they care about is the end result.

If your website has F Score and loads in 1 second, but another site has B Score but loads in 1.5 seconds, whom do you think search engines and your users are going to prefer? Around 95% of the speed of a website is down to the hosting, unless you have serious configuration errors or unconventional use.

I recommend that you spend more time on matrix's that actually matter, the outcome. Using Web Page Test you can target your audience's region and do multiple passes. I recommend doing 10 passes from multiple locations at the same time as one another.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.