What should I do when GTMetrix tells Compress https://cdn.segment.com/analytics.js/v1/platform/analytics.min.js?

130 views Asked by At

I am analyzing our website with GTMetrix.com and they're telling me:

Compressing https://cdn.segment.com/analytics.js/v1/platform/analytics.min.js could save 85.5KiB (71% reduction).

I'm not even sure where that script is coming from or what's loading it. This is a WordPress website, so it could be a plugin... I just know that we lost 8 pagespeed points when that thing started showing up. How do I enable this gzip for this, or replace the file in WordPress? The website is https://stryvebiltongorders.com/

2

There are 2 answers

0
Petr On

There's a "Segment Analytics Code" on your page. Some kind of metric js-script I think. You can't gzip it. Because it's not on your server (you have not got an access to it). But you can try to delete script from your website.

0
Sajjad Hossain Sagor On

At this point nothing you can do unless the file is in your server! Either keep it as it is or you can remove the file to reduce 100%. Also you could serve the file from your server that way you can gzip it and add a cron job to fetch newly fresh version of the file everyday or something.