Keep Alive / persistent connections

Just found this very handy tool. Great stuff!

Run a test here

Apart from some obvious ones, it states that none of the files have a Keep Alive header. Afaik they do, and Firebug confirms this (see attached image for global.css; others are similar).

Any thoughts/ideas :huh:


Hey Ruud,

If the website is on your own server, try going to Internet Information Services (IIS) Manager.

Right click your website on the left and click properties.

Make sure “Enable HTTP Keep-Alives” is checked.

I have a Windows server. This worked for me except for coldfusion pages. I am still working on that part.

Travis Walters

Hey Travis,
Thanks for the respons.

I use a shared hoster who uses Apache 2.x. So can not tweak as much as I might like (but it keeps me also from breaking it…).


Ping the support line for your hosting provider. It’s not uncommon for there to be a BrowserMatch line in the httpd.conf that inadvertently disables keep alives for all IE versions (it’s usually in there for IE6 SSL reasons or something like that). That’s usually why it looks fine in Firefox but not IE.

Probably worth checking your .htaccess if you have one to make sure the BrowserMatch line isn’t in there as well.


Hey Pat,

Awaiting answer from my hoster. Will post here when they come back and if it is solved.

PS afaik this setting is not available in htaccess files; only on server configuration level.

The keep alive setting isn’t available in .htaccess but you can break it in .htaccess. Since it’s working in fiirefox the global setting is fine but somewhere there is a BrowserMatch rule that is disabling keep-alive for IE.

BrowserMatch “MSIE 4.0b2;” nokeepalive downgrade-1.0 force-response-1.0

is a sample from the apache docs that will force IE 4.0b2 to get HTTP 1.0 responses and no keep alives. It’s probably some variattion of a similar line done for different reasons but it’s catching more browsers than it should because the browser string is probably being applied to all IE versions (either in their config or one of your .htaccess files).

thanks for the support sofar.

Checked my htaccess files, and no trace there. Has to be at server level.

Waiting for my hoster to come back and let you know.

BTW great tool is Fiddler2 that allows to fiddle (duh) with the headers etc and shows very nicely what happens with an User Agent set to IE or not. Runs with IE and FF.

Ok. Got respons back from hoster that they do have the setting as in Patrick’s reply.

Afaik that should ONLY affect IE4 User Agents, and not anything else. Correct?
In my situation it does close the connection for IE8 for example. What should they be looking for, or what should be changed?

BTW the hoster is very reluctant to change ‘a standard setup’ and points towards a VPS solution they have. Not what I want of course, since it should work properly with those IE versions that support correctly persistent connections.

Can you have them provide ALL of the BrowserMatch lines from their httpd.conf that include MSIE? If I had to guess, they don’t have the exact line I posted and theirs is accidentally whacking ALL versions of IE.

I understand their aversion to changing the standard config but on the flipside, it also means that persistent connections are broken for ALL of their customers.

According to my hoster these are all BowserMatch settings in their server configuration:

BrowserMatch “Mozilla/2” nokeepalive
BrowserMatch “MSIE 4.0b2;” nokeepalive downgrade-1.0 force-response-1.0
BrowserMatch “RealPlayer 4.0” force-response-1.0
BrowserMatch “Java/1.0” force-response-1.0
BrowserMatch “JDK/1.0” force-response-1.0

Looks like a real out of the box installation and I see no indication here why IE gets its connections closed. BTW they use Apache 2.

Any other ideas left, or should I live with it?

Looking at the headers that were used on your tests and those rules I don’t see any that should have been triggered either. I certainly wouldn’t recommend giving up because it’s a pretty big performance deal (close to a second if not more) and if it really is being caused by their base install it’s happening to all of their customers on the shared hosting.

Is there any way to stand up a simple test page that is just a straight static html page with a few images (and no .htaccess) in a top-level directory somewhere for testing?

Honestly, if you can prove it is from their config, their engineers should be working to figure it our and if there are any forums or discussion groups it would be worth checking to see if other customers are seeing it and to get more pressure applied.

Worst case I’d recommend switching providers - you shouldn’t have to go with a VPS plan to get reasonable shared hosting ( is on Dreamhost shared hosting for example and they do not have the same problem).

already set up a single static html page w/ js, css, img results are the same: no keep alive at all

The hoster did not react at all to my comment that ALL IE users are experiencing this. So, I guess they have resources to burn and/or want people to switch to more expensive hosting plans.

Are there other companies that offer similar shared hosting in the region you are operating in? Seems like that would be a SIGNIFICANT competitive advantage in marketing, particularly with performance now being a (small) part of pagerank. I’d switch providers before I’d pay that one more for being incompetent.

there are other hosters of course. I’ll start looking around, but have to move 12+ sites… not a trivial thing.

Q: all tests are done with IE versions; why is there not a FF version? Would be interesting to see the difference between the two, as in my case.

The pagetest browser plugin that is used for testing is specific to IE. Firefox support is being considered but it’s a pretty big effort.


I inherited a web server configuration with this included:
SetEnvIf User-Agent “.MSIE.
nokeepalive ssl-unclean-shutdown
downgrade-1.0 force-response-1.0

I’m guessing it’s coming from this page:

Our entire site is through https. Is this only for IE6? I have keep alives enabled elsewhere in apache, but in my page test (using IE7), it says no keep alives are being used.

Unfortunately, we have to support IE6 for one of our clients. I would at least like to speed it up for our others, though. How can I change this config?


It looks like that is a pretty ancient problem (IE 5.x):

You could also just put that config in a vhost section for the one customer: