Home > Mobile >  Problem with Page has redirected JavaScript
Problem with Page has redirected JavaScript

Time:06-25

I did an audit of my website and it sends me this message

"Page has redirected JavaScript"

Issue details Some pages on your website link to JavaScript files via a redirect. This forces web browsers and search engine crawlers to make an additional HTTP request in order to reach the destination JS file URL. On a vast scale, this can increase page loading times for your website.

How to fix Review the pages that have a link to the redirecting URL and replace this link with the direct link to the destination JS file. If you decide to keep links to redirecting URLs that do not belong to your website, make sure that the destination files are relevant.

And I get several links like these:

https://script.crazyegg.com/pages/scripts/0012/9265.js https://s7.addthis.com/ with randoms numbers

Has anyone had a similar problem who can help me to see how to solve the problem?

CodePudding user response:

It sounds like you have some pages that are actually loading a remote JS file, which then redirect to another page on your website.

Why this is happening is anyone's guess - maybe you have a plugin installed that is doing it intentionally as part of it's functionality. I would start by disabling plugins one at a time (ideally on a staging environment) until the problem goes away, and then you'll know who the culprit is and make a decision.

  • Related