Live data from Hacker News

Does CloudFlare really speed up your site? Tests say not really.

blog.dh42.com

41–50 of 61 posts

Re: Does CloudFlare really speed up your site? Tests say not really.

#41
We ran some tests on using CloudFlare for our S3 assets. It didn't speed things up at all.

On top of that, quite a few people have reported that CloudFlare would serve CAPTCHAs to users / mark the site as down and serve a static version. Anecdotally, I have seen this happen before browsing CloudFlare-enabled sites once or twice.

One other issue we saw: the incorrect image was once served. That was pretty disconcerting.

Between all of these issues, we gave up and ended up using CloudFront. It's a shame because CloudFlare is so much more feature-ful and pleasant to use. But I don't think it's a mature product yet.

Re: Does CloudFlare really speed up your site? Tests say not really.

#42

If you are fronting a heroku-based app on their cedar platform and have rails (or whatever) serving up static resources CloudFlare is a no brainer: you free up your dyno's to handle the dynamic stuff, and it's a few config-clicks to get it going, with no crazy asset deployment steps. Additionally, for the cost of just Heroku's SSL endpoint per month, CloudFlare will effectively issue you a wild-card SSL cert (hundred…

My experience with CloudFlare couldn't be more to the contrary. We rolled it out for a good few months and gave them quite a while to get their act straight. Ultimately, we had to do an emergency switch to another CDN because the performance was SOOOOOO bad and we had an important event occurring the following day (Not the ideal time to be playing with DNS on a production website). The Theory behind CloudFlare makes…

My concern is more about scaling than raw page speed: of course going through a reverse proxy is going to be slower end-to-end than going directly to heroku. But taking the static asset load off of heroku without a Rube Goldberg CDN deployment is great, IMO: they just leverage standard HTTP caching headers and then those requests rarely if ever hit your dynos, like the old varnish functionality you got with bamboo stack on heroku. It's much more brain dead, which works for me.

I don't use or care much for all the dynamic optimization they offer (I turned it all off) and, with respect to the SSL cert, I don't really care about how it is issued (to a first approximation, no one looks at certs except the browser verifying the cert against the URL) but YMMV.

It does appear that wildcard certs have gotten very cheap now: http://www.namecheap.com/ssl-certificates/comodo.aspx so the cost savings isn't as great as I thought. (Thanks for pointing that out aioprisan.)

I've found that heroku performance thinking is a bit different than raw page speed thinking: my goal in life is to minimize the load on my dynos. I'd be willing to put up with a CDN that was slower serving static assets than heroku is, just to keep the load off the dynos, but I've found CloudFlare to be plenty fast.

Re: Does CloudFlare really speed up your site? Tests say not really.

#43
I'm not surprised he got these results. While the author raises some valid points there are a lot of flaws with this. He doesn't say what the times are for. Is it the time to DOM ready? To the page completely loaded and rendered? Did he load each site at least once before running the tests to make sure CF's caches were primed?

CloudFlare can make your site faster or slower depending on how you use it and what you're serving through it. Since it's a proxy response times will be higher for dynamic content it needs to fetch (the page itself, unless it's cacheable). Static content (with proper cache headers) will be served through its CDN (everything else) which will almost always be faster, again assuming CF's cache is primed.

The author's finding may be accurate about a base level install of these platforms with no performance improvements. I believe that without proper caching headers CF is going to have to query your server for everything to make sure nothing has changed. Sending proper cache headers with your static files will eliminate this issue and improve your performance. AFAIK none of these platforms use proper caching headers out of the box.

One last nitpick. Why the hell is this article spread across 6 pages? That's incredibly useless, annoying, and takes away from the user experience.

Edit: Originally I called out the author for claiming his site has a PageSpeed score of 97. I did so because the site issues 57 requests, including 8 CSS and 20 JS files, some of which aren't even minified. I assumed there was no way his score could be 97 with these glaring issues. Turns out I was wrong. I tested it[1] and it does have a score of 97, which just goes to show that PageSpeed and YSlow have plenty of their own issues. IMO his site shouldn't have over a 90 based on these obvious and easy to fix flaws.

1: http://www.webpagetest.org/result/130105_G4_DEA/

Re: Does CloudFlare really speed up your site? Tests say not really.

#44

If you are fronting a heroku-based app on their cedar platform and have rails (or whatever) serving up static resources CloudFlare is a no brainer: you free up your dyno's to handle the dynamic stuff, and it's a few config-clicks to get it going, with no crazy asset deployment steps. Additionally, for the cost of just Heroku's SSL endpoint per month, CloudFlare will effectively issue you a wild-card SSL cert (hundred…

you can get a wildcard cert for less than $90/year. I got mine for $40 with a special on namecheap.com

Wow, I didn't realize how cheap they had gotten, thanks for pointing that out! I may pick one up just because.

Re: Does CloudFlare really speed up your site? Tests say not really.

#45

If you use a Wordpress blog and the W3 Total Cache plugin (the one that's most recommended and versatile), it has native CloudFlare support. Using that, I've survived a HN+Reddit spike, no sweat.

I think that is somewhat the point of the OP. If you're average joe and just want to click a few buttons WTC + cloudflare is popular. If on the other hand you don't like bloated problem inducing options, you do it yourself. For example;

Throw in Paul Irish's .htaccess boilerplate: https://github.com/h5bp/html5-boilerplate/blob/master/.htacc...

Enable APC http://wordpress.org/extend/plugins/apc/

Minify using a build script

Use one of the Many CDN plugins for images.

If you're worried about load balancing and DDOS there are plenty of solutions out there that are handled at the host level.

Re: Does CloudFlare really speed up your site? Tests say not really.

#46

I'm not surprised he got these results. While the author raises some valid points there are a lot of flaws with this. He doesn't say what the times are for. Is it the time to DOM ready? To the page completely loaded and rendered? Did he load each site at least once before running the tests to make sure CF's caches were primed? CloudFlare can make your site faster or slower depending on how you use it and what you're…

I don't really understand Cloudflare's problems with latency. When using FULL CDN+Optimizations the entire site's HTML and assets should be cached and served super fast via cloudflare. That is the best case scenario for them to speed up load times.

But based on my testing, Cloudflare adds more latency to response times even in a best case scenario of full caching. However, when I do the same exact type of optimizations with Google PageSpeed service I see great results.

The most interesting part about cloudflare's problems is that they weren't there 2 years ago when I first started using it. I blogged about how great it was.

Here are the articles I've written about cloudflare in the past 2 years: http://www.x-pose.org/category/cloudflare/

Re: Does CloudFlare really speed up your site? Tests say not really.

#47
post #26

I stopped using Cloudflare because of their "protection service". They would block certain visitors, seemingly by random, and present them with a captcha. The page presenting the captcha had big ads on them. There's no way that it's acceptable to show ads and captchas to potential customers, before they can even see my website.

I believe paid accounts can customize the challenge page, but moreover even free accounts can turn the security completely off so no one ever sees it.

Re: Does CloudFlare really speed up your site? Tests say not really.

#48
It's unclear if the tools used (Pingdom/Neustar) put cache-busting headers on their requests. It's likely that they do: such probes are more comparable/reproduceable between runs, and more likely to give guidance to the app-designer/web-designer (as opposed to cache-runner).

If so, of course CloudFlare would be slower in such tests: its largest benefit, caching unchanged resources for subsequent reloads, has been disabled.

Also, it's hard to take performance hints from someone who splits such a short, simple blog post across 6 (!) pages. Six discretionary click-requiring page-loads is always worse than one, and is the easiest thing to fix if you're respecting my reading-time.

Re: Does CloudFlare really speed up your site? Tests say not really.

#49

Earlier quoted context omitted.

My experience with CloudFlare couldn't be more to the contrary. We rolled it out for a good few months and gave them quite a while to get their act straight. Ultimately, we had to do an emergency switch to another CDN because the performance was SOOOOOO bad and we had an important event occurring the following day (Not the ideal time to be playing with DNS on a production website). The Theory behind CloudFlare makes…

My concern is more about scaling than raw page speed: of course going through a reverse proxy is going to be slower end-to-end than going directly to heroku. But taking the static asset load off of heroku without a Rube Goldberg CDN deployment is great, IMO: they just leverage standard HTTP caching headers and then those requests rarely if ever hit your dynos, like the old varnish functionality you got with bamboo st…

For your thing about not looking at certs... that's not true since all browsers now show the 'O' in the address bar for EV certs. And people definitely look at those, in my experience.

Re: Does CloudFlare really speed up your site? Tests say not really.

#50
I have to wonder about the testing results that were obtained. Testing the improvements of optimizations need to be done carefully; you need to make sure capture sufficient data to draw conclusions.

#1 -> You need to capture enough data samples for each location and browser #2 -> You need to capture data from a set of global locations #3 -> You need to capture data from the commonly used web browsers.

You can see a test run from a single location and browser using one sample (2.873) second for the time to interact.

http://www.websitetest.com/ui/tests/50e89376479876092f000012

but when you run the test over 17 location and run 5 samples for each locations. (6.4) second for the time to interact.

http://www.websitetest.com/ui/tests/50e893d7479876092f000016

There is a big difference between the one location and the multiple locations with 5 samples. Looking at just Washington with 5 samples; the time to interact is (4.1) seconds.

(Disclosure, I work at yottaa.com the provider of websitetest.com) For those people looking to verify optimizations are working (automated or hand-tuned) you should use websitetest.com to simplify the testing process. It makes running tests (multiple locations, multiple browsers, multiple connectivities) possible with one click and test results make it easy to draw conclusions.

--- All test data for the information in the comment is available through these links

Tests by browsers in Washington DC -> http://www.websitetest.com/ui/tests/50e89598479876124100000e

Post reply on HN