Facebook is slow, but there’s an easy fix
It seems like the Facebook engineers add another javascript and css file to their pages with every new feature. As of today, viewing the Facebook homepage loads 36 javascript files from Facebook and 4 more from advertisers. In addition to these 40 files, there are 12 css files.
That’s a lot of files! If you’ve ever noticed the excessive flickering happening in your browser’s status bar when you go to Facebook, this is the cause.
How can they improve the situation? The total file size isn’t too terrible at about 100k of JS and 40k of CSS. The best thing to do would be to use a simple build script that concatenates all these files together into one larger file. If they can’t do that for some reason, they could at least serve the files from more than one domain to take advantage of parallel downloads in the browser. They could also try a service like Akamai, but that’s a bit more complex and expensive.
This seems like a really silly oversight from an organization that in general produces beautiful work. My guess is that when the company was getting started they set up a relatively simple build process that has now become ingrained and difficult to alter as their setup has quickly become larger and more distributed. However, they’ve reached the point where it’s time to revisit things and do it properly.


November 22nd, 2007 at 5:43 am
I may have a better solution: don’t bother even visiting Facebook, since it’s alread becoming passé.
March 26th, 2008 at 2:04 am
Useless post.. does not explain how to fix the actual problem! Waste of 1 minute.
March 27th, 2008 at 1:06 am
Its a good post - explains the problem, suggesting a solution on Facebook’s part. Good job
April 7th, 2008 at 2:21 am
Useless post
April 10th, 2008 at 4:21 pm
Technically correct, but absolutely useless.
April 12th, 2008 at 1:26 pm
could maybe one of you cleverheads, or a really clever one tellus not so clever ones a second solution instead?
thanx in advance ( and good hope)
April 20th, 2008 at 12:04 am
Does not help me at all… send it to facebook… im still wondering whether to go have a shower or have my lunch or rather do both while facebook continues to load!!!!!
April 25th, 2008 at 12:53 pm
I am writing this as I wait for Facebook to load… I thought it would have been down to the amount of traffic, although as it’s 9am I would imagine it isn’t ‘peak’ time so I agree it must the scripting.
Message to Facebook - get your finger out, for one of the worlds biggest social networking sites, this is pathetic.
Oh, great ‘Problem loading page’. What a surprise.
May 1st, 2008 at 2:55 am
Cannot believe this, once I get into the swing of things this silly site decides to work EXTREMELY slow! What’s going on facebook?? sort it out pls!
May 1st, 2008 at 8:15 pm
Yea Facebook is getting damn slow from this past week!!!.. they need to do something quick.. im running out of patience.
May 3rd, 2008 at 3:33 pm
Are most people using IE to view Facebook? I’ve found that Firefox now seems to deal with Facebook a lot quicker than IE does, so have started using that instead.
I’m not an MS basher - I usually find IE more functional than Firefox in general (bet this will generate some flames!) so I still use it for other browsing, but it may be worth a try if you visit Facebook frequently.
May 8th, 2008 at 6:31 am
did that !@# at the top actually say ‘passe’
whats passe, getting in touch with old friends
doing business…? or just being a facegeek…
i agree its a bit overhyped, and its not perfect, but it serves a very good purpose
…sorry, its just…
besides, who says ‘passe’
damn!
May 27th, 2008 at 7:48 pm
This past week I keep getting timeout errors when trying to log in to facebook. The login page comes up quickly enough, and I was also able to browse their help pages fast as well - but when I key in my email and password, then hit the login button, the page goes white, sits for a while and then I get the timeout error. A right royal pain in the rocks! Every other webpage I visit is working as normal. Any ideas what this could be?
Cheers,
J
May 31st, 2008 at 12:38 am
Same from Switzerland (MUCH slower since abt 3 weeks, timeouts, etc.)…
But indeed, apart from the good feeling of not being the only one with the problme, quite a useless post (what is the fix?)
May 31st, 2008 at 12:45 am
If you want a fix, I’d suggest forwarding a link to this post to Facebook. They’re the only ones that can fix this issue.
June 1st, 2008 at 1:02 am
[…] And the explanation is here. […]
June 23rd, 2008 at 10:49 pm
I’m not a fan of facebook (faeces book as I call it). Kind of ditched them when I discovered Microsoft had dibs in their advertising.
Here’s a tip which may help though, install a hosts file on your PC that blocks their advertising - okay, it wont fix all the issues.
Just these may work (not sure)
127.0.0.1 ads.facebook.com
127.0.0.1 ads.ak.facebook.com
Alternatively - visit here http://www.mvps.org/winhelp2002/hosts.htm where there’s plenty of information and a good hosts file you can use.
July 25th, 2008 at 3:37 am
HERES YOUR BEST AND QUICKEST SOLUTION
download latest version of safari from http://www.apple.com/safari/download/
seems to handle facebook easily and is a pretty quick fix,but you will need to download the FLASH plug-in from here and install it,very very easy!
works so much better for me,im using windows xp sp3 with all updates.
July 28th, 2008 at 9:38 pm
Good post, and I completely agree.
They should somehow concatenate this stuff, and make it more “browser cache” friendly. Since even with this multitude of javascripts/stylesheets they have — it is still being served in a way that each request gets a new file. And the browser cache (especially firefox) does not store it for faster loads in the future.
August 18th, 2008 at 7:52 am
Useless post, thanks for nothing and the waste of time!
September 13th, 2008 at 1:17 am
A good solution is using a browser that handles javascript faster and renders pages quicker. I believe the quickest are Safari and Google Chrome. Firefox and Opera are also good alternatives. The site does need a redesign, however most Web 2.0 sites now use Javascript AJAX etc, so the browser will make a difference.
November 12th, 2008 at 4:01 pm
seriously facebook needs to sort it shit out!! - it worked just fine to begin with and it was easier to use and then they had to go and change it all and make it all sh**t and complicated resulting in it not f&^%kin working at all! SO frustrating!!
November 20th, 2008 at 2:54 pm
No one yet gave a solution,waste of time.
December 5th, 2008 at 3:25 am
Looks like its a DNS to me. Once the IP is cached locally, the page loads at an OK response time.
Try this: http://69.63.178.11 and see how fast it loads.
———-
dig facebook.com
; <> DiG 9.5.0-P1 <> facebook.com
;; global options: printcmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25316
;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 0
;; QUESTION SECTION:
;facebook.com. IN A
;; ANSWER SECTION:
facebook.com. 2359 IN A 69.63.178.11
facebook.com. 2359 IN A 69.63.176.140
;; Query time: 22 msec
;; SERVER: 208.67.220.220#53(208.67.220.220)
;; WHEN: Thu Dec 4 17:26:44 2008
;; MSG SIZE rcvd: 62
December 14th, 2008 at 12:31 pm
Yeah i am getting the same problem with facebook. The problem is that this morning i was on facebook (At Parents Place) and it wasn’t having any problems using it (On IE).
This afternoon I arrived back at my place and hopped back on (through Firefox) and it is not working at all.
Cannot use IE on my system as it just locks up. I was on Facebook at my place 2 days ago chatting to a friend , no problems that day, but today Facebook is driving me crazy.
FACEBOOK - DO SOMETHING ABOUT THE SLOW RESPONSES.
April 3rd, 2009 at 9:44 am
yeah… same problem we may know.. the Facebook is too damn slow now days. IE or Firefox cant fix this. Where the hell their geek man? facebook doenst have any engineer to fix this???
April 8th, 2009 at 9:07 am
ok - - I at least feel better that it’s not just me…. I switched internet providers party (like 20%) because of this. I have a T1 at the office and Facebook is fine….. but COME ON!!! I mean a 2-3 second lag on typing when I’m on here at home?
April 22nd, 2009 at 2:21 am
damn slow
to many uselessssssssssssssss aplication !
AND tom many ‘crazy’ persons playing game on it
not for social community anymore :(
April 22nd, 2009 at 6:23 pm
facebook is going dead
April 26th, 2009 at 5:38 am
So what is the easy fix ?
April 28th, 2009 at 10:16 pm
I know an easy way that worked for me.. change web browser. IE was super slow, but when I changed to Mozilla Firefox it worked fine!
May 31st, 2009 at 4:42 am
The answer is Akamai. Simple as that.
May 31st, 2009 at 10:57 pm
Bryan, that link you suggested got me to facebook’s home page just fine but I tried to log in and it said “page load error”.