Cloudflare vs No Cloudflare - Tested

xha44a

New member
Jan 11, 2013
98
1
0
Hi,

So I remember reading a while ago a post by the legendary CCarter about Mito Tags on Speed. Came up with the idea of testing this out myself. Figure I'm going to hit this thing and make my sites rip. So the first thing I did was naturally fire up Pingdom Tools and run a website of mine through it. Here's what that looked like...

screen.png


This was very painful. Almost 4 seconds to load a simple 1 MB page? And most of the time (not visible in this screenshot) was due to WAITING for my server. I had up to 400 MS wait for some connections... unsure if this was due to a max simultaneous connections setting on my server or what. No idea.

Anyway, I decided I might take a second to try and fix/tweak this. I'm using Cloudflare as a CDN (also provides some uptime benefits) and figured I would turn it off first before I begin fiddling around with my Apache settings for my VPS. Yes - that's a 4 second load time on a VPS. Pretty abysmal. Long story short... I turned cloudflare off, and gave it time. Overnight actually - ran out of time to work - and then tested it again. Surprise, surprise... load time dropped substantially.

withoutcloudflare.png


At this point I was thinking what the heck? I didn't change anything really yet, and the load time drops so substantially? I dropped some serious time

Thinking - this can't be right - I decided to run another test turning cloudflare back on. I turned on Cloudflare and went to do some chores for 40 minutes (in case any kind of cache/refresh issues) and then tested it again...

withcloudflare.png



Summary: 3 Tests of load time. With and Without Cloudflare

With Cloudflare: 3.85 s
Without Cloudflare: 1.46 s
With Cloudflare: 2.86 s


On taking a closer look, it seems Cloudflare introduced some serious wait time at the very first file load. Without cloudflare first connection was waiting 100 ms. With cloudflare it was waiting 600 ms - 1400 ms.

Long story short. Test this stuff before you assume it's a good idea. I'm going to be testing it again w/o cloudflare. If it's really cloudflare slowing my site, I may just use it for DNS.

Now I know there will be server differences, but anyone care to confirm it on their website?

Cheers!

XH
 


I really think you need watch the performance over time for each setup and take an average rather than these 1 page load spot tests. I would be surprised if you ran this test again with the same conditions (that you have control over) you would get the same results.
 
Normally the page will load faster on subsequent load. Eg. 2nd time is always faster than 1st load.

And I have also noticed that using cloudflare might have some negative seo effect (sometimes not negative, but it buffers away some positive effect)
 
I really think you need watch the performance over time for each setup and take an average rather than these 1 page load spot tests. I would be surprised if you ran this test again with the same conditions (that you have control over) you would get the same results.

Point taken. I would caution anyone from drawing conclusions from this. It just freaked me out when I tested the same thing a few minutes apart and cloudflare was horribly worse. Not sure why this happened. It totally could be different issues - which is why I issued the call for others to test the same thing ;-)

Normally the page will load faster on subsequent load. Eg. 2nd time is always faster than 1st load.

And I have also noticed that using cloudflare might have some negative seo effect (sometimes not negative, but it buffers away some positive effect)

I understand caching will affect page load time. However when page load time went UP substantially on the second test by turning cloudflare ON - that's not caching. I can't prove it's cloudflare, but I can't prove it's not. Test it on your site and let me know what you get.
 
If your index page is dynamic it will nearly always be slower via cloudflare as it is in effect acting like a proxy. There are exceptions, i.e. CF's route to your server is 500ms faster than your ISP's, or your DNS server is particularly slow, but this is pretty rare.

CF (imo) is really only useful for performance gains, when your site is static or when your server is badly configured and you turn on aggressive caching.

I use CF on a subdomain, from which i serve js, css and images, the result is consistently faster, plus less requests/bandwidth to my servers. I rarely use it on the domain itself, unless it is mostly static and turning on aggressive caching is possible without ill effect.

Using it this way I get the DNS anycast benefits of CF, which are great.
 
Not sure where you are, but your first test was from the Netherlands and the others from USA. I always test from my nearest location, seems to make sense.
 
Not sure where you are, but your first test was from the Netherlands and the others from USA. I always test from my nearest location, seems to make sense.
Agree, this is always how I test my sites speed too. Seems especially important when testing things out.
 
Did you test on a different page the second time around? Likely, it loaded faster the second time due to caching. Anyway, Cloudflare is standard with many hosts now and lots of people swear by it. Though I have mixed results using Cloudflare.