Take the 2-minute tour ×

Google chrome sends multiple requests to fetch a page, and that's -apparently- not a bug, but a feature. And we as developers just have to deal with it.

As far as I could dig out in five minutes, chrome does that just to make the surfing faster, so if one connection gets lost, the second will take over.

I guess if the website is well developed, then it's functionality won't break by this, because multiple requests are just not new.

But I'm just not sure if I have accounted for all the situations this feature can produce.

Would there be any special situations? Any best practices to deal with them?

Update 1: Now I see why my bank's page throws an error when I open the page with chrome! It says: "Only one window of the browser should be open." That's their solution to security threats?!!

share|improve this question
do you have a link to anywhere this is officially documented? –  fearofawhackplanet Dec 16 '10 at 12:22
I got this from a question in stackoverflow: "Chrome is trying some aggressive tactics in its developer builds (I think that is cool). What they're doing is speculatively opening sockets to servers, and also opening a second socket if their first attempt doesn't get a response quickly enough. It's pretty easy to see how a bug in this stuff, or even just the expected behavior, could trigger abuse filters. But, as I said, I think it is worth doing. All these web startups will make more money if the Web is faster." –  Cg Alive Dec 16 '10 at 12:30
A Chromium issue touches on this code.google.com/p/chromium/issues/detail?id=39402#c11 –  jrummell Nov 9 '11 at 21:09
add comment

7 Answers

Your best bet is to follow standard web development best practises: don't change application state as a result of a GET call.

If you're worried I recommend updating your data layer unit tests for GET calls to be duplicated & ensure they return the same data.

(I'm not seeing this behaviour with Chrome 8.0.552.224, by the way, is very new?)

share|improve this answer
I'm using the same version, but I see the behavior. Try calling a script that increments a number in a file. –  Cg Alive Dec 16 '10 at 13:40
I've not managed to reproduce it, I wrote a quick script which appends to a file and I only get one line in the file per click. I'm using the Linux build so maybe it's not enabled there yet –  Peter Dec 16 '10 at 14:05
add comment

I saw the above behavior while writing my server application and found that earlier answers are probably not true.

I have attached screen shot of packet capture through wireshark.

It is for a simple get request to port 8080 for which my server returns a hello message.

Chrome sends the second get request for obtaining favorite icon which you see on top of every tab opened. It is NOT a second get to cater time out or any such thing

Here is a reference question that i found latter

Chrome sends two requests SO

chrome requests favorite icon

Chrome issue on google code

share|improve this answer
add comment

This only happens when I enable "webug" extension (which is a FirePHP replacement for chrome). If I disable the extension, server only gets one request.

share|improve this answer
I apologize for this error in Webug — in the current version it is fixed. –  fedosov May 23 '13 at 9:08
add comment

I have just implemented a single-use Guid token (asp.net/TSQL) which is generated when the first form in a series of two (+confirmation page) is generated. The Token is recorded as "pending" in the DB when it is generated. The Guid token accompanies posts as a hidden field, and is finally marked as closed when the user operation is completed (payment). This mechanism does work, and prevents any of the forms being resubmitted after the payment is made. However, I see 2 or 3 (!?) additional tokens generated by additional requests quickly one after the other. The first request is what ends up in front of the user (localhost - so ie., me), where the generated content ends up for the other two requests I have no idea. I wondered initially why Page_Load handlers were firing mutliple times for one page impression, so I tried a flag in Http.Context.Current - but found to my dismay, that the subsequent requests come in on the same URL but with no post data, and empty Http.Context.Current arrays - ie., completely (for practical purposes) seperate http requests. How to handle this? Some sort of token and logic to refuse subsequent page body content requests while the first is still processing? I guess this could take place as a global context?

share|improve this answer
add comment

It also happens in asp.net postback call. I am so far dodging a bullet b/c it only happens on localhost.

When I click submit, a postback occurs and the code inserts a row into the database, and then redirects to another page. But with the double request, which occurs immediately after the redirect statement is executed. Results in the same code running twice and 2 rows inserted into the table.

I need an easy solution for this.

share|improve this answer
add comment

I'm having the same bug. And like the previous answer this issue is because I've installed the Validator chrome extension Once disable the extension, works normally.

share|improve this answer
add comment

I was having this problem, but none of the solutions here were the issue. For me, it was caused by the APNG extension in Chrome (support for animated PNGs). Once I disabled that extension, I no longer saw double requests for images in the browser. I should note that regardless of whether the page was outputting a PNG image, disabling this extension fixed the issue (i.e., APNG seems to cause the issue for images regardless of image type, they don't have to be PNG).

I had many other extensions as well (such as "Web Developer" which many have suggested is the issue), and those were not the problem. Disabling them did not fix the issue. I'm also running in Developer Mode and that didn't make a difference for me at all.

share|improve this answer
add comment

Your Answer


