Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7937371
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T22:30:27+00:00 2026-06-03T22:30:27+00:00

<!—Firefox Prefetching –> <link rel=prefetch href=http://www.example.com/page2.html> <!—Chrome Prefetching –> <link rel=prerender href=http://www.example.com/page2.html> If I

  • 0
<!—Firefox Prefetching -->
<link rel="prefetch" href="http://www.example.com/page2.html">

<!—Chrome Prefetching -->
<link rel="prerender" href="http://www.example.com/page2.html">

If I had Javascript on the page to prerender/prefetch (such as Google Analytics JS), will the prerender/prefetch execute Javascript on the page? Or does it delay any execution of JS until the page is actually requested by the user?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T22:30:29+00:00Added an answer on June 3, 2026 at 10:30 pm

    I’ve just done some more research on this:

    Prefetch will load the top level resource which is often simply the HTML page

    Prerender will fetch child elements as well, and will execute Javascript code. Using the Page Visibility API we can determine the current visibility state of the loaded page.

    So the answer is yes, it will execute JS as long as the user is on Chrome and prerender is being used. Also, the current version of Google Analytics makes full use of the Page Visibility API so statistics wont be skewed, however it’s likely there is a lot of code in the wild whose statistics are being skewed by not properly handling cases of prerendering.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Firefox: http://example.com/about/#anchor -> http://www.example.com/about/#anchor Internet Explorer 6-8: http://example.com/about/#anchor -> http://www.example.com/about/ Why is the anchor
Firefox seems to be forcing the HTTP Method: LINK in particular to Link on
Firefox, does not seem to display the table with scrolling correctly. Safari, and Chrome
In firefox on link hand cursor is showing which is ok but in IE7
Firefox has an Xpather extension that allows one to inspect html and extract xpaths.
Firefox and Chrome are known to be slow on localhost when IP6 is enabled.
Firefox is for some reason not properly handling content sent through my .NET HTTP
Firefox has a certain tolerance when rendering bad HTML. This means even if a
Firefox has the Sandbox and evalInSandbox(). Chrome has sandboxed execution in their content scripts
Firefox appears to be refusing to style an html element if i use the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.