Why Facebook is so slow

I have just read a blog post which comments about the average time it takes to load a page on various social networking sites.

Regarding Facebook it says: “despite its popularity amongst users, the network took the longest to load up.”

Now, I’m not an American teenager, but … well duh!

I think the sentence should be converted to “due to its popularity amongst users, the network took the longest to load up.”

The post also mentions that Faceparty is one of the fastest loading social networks - this is not so surprising if you consider that it was the first social networking site to have mass appeal back in 2000 or so.

Anyone can build a social networking site. The biggest problem with them is to handle the load on the servers when they explode in popularity.

Q. If Google can present a zillion search results in milliseconds, why does Facebook take so long to display a pretty profile?

A. Both search engines and social networking sites have intense load from users’ demanding information retrieval. However, unlike search engines, social networks have the added pressure of users expecting high speed updates of information. Updating information is more intensive than reading information - hence Mark Pors, chief technical officer at WatchMouse, should not be so surprised by the slowness of these social networks.

Related posts:

Building a Facebook Application

Update 2008 10 25
Google Chrome - Google’s fine example of a web Browser - has a show processlist feature. In a traditional OS Task manager you just see one process to represent the browser. Google Chrome splits the various aspects of web page/script rendering into individual processes - so we can get a really good view of what’s happening under the bonnet and see which parts of a web site are causing problems. As yet, I have not checked out facebook with it - but it could come in handy if anyone’s interested in it.

18 Responses to “Why Facebook is so slow”

  1. mart kyr Says:

    you dont know much do you?

    the reason facebook is so slow has nothing at all to do with the load on the servers, the reason its so slow is the fact that the applications that runs on it are coded terrible, and completly hammer your browser using more ram and more cpu cycles…

    load a freshly made profile on facebook, it will load in miliseconds, load a popular persons profile, who has lots of friends and lots os stupid applications installed on there profile, it will take for ever to load.. but while your waiting, hit ctrl alt and del and check out how much cpu and ram usage your browsers executable file (firefox.exe or iexplorer.exe) is using.. 100%

    you know nothing about web servers

  2. admin Says:

    I know more than the average person about web servers. But, I admit there is a lot that i don’t know. If you are implying that updating information is not more intensive than reading information then I guess I know more than you about databases.

    The number of applications on facebook could well be another reason why it runs slowly - so no argument with you there.

    The main point of the post, therefore, still stands true - it is not very surprising that facebook is slow.

  3. annoyed user Says:

    Its annoying either way, I would have thought that due to its high popularity the Facebook guys would have got themselves a few extra servers to handle the strain… that and regulated the stupid Apps that keep popping up… or maybe just get rid of the 3rd party ones?

  4. Hintswen Says:

    to annoyed user

    You realize that most of the apps are 3rd party?
    Have you ever looked at the list of apps that are not 3rd party?
    It’s basically the few that are installed automatically when you make your account and about 20 more.

  5. wtf-er Says:

    why the hell did you compare facebook with google searching?

    google has an index, facebook is another story.. it might have its own index, but it has to be a heavier index… google simply has URLs and sitemaps..

  6. Wayne M Says:

    Facebook runs pretty good for how many requests it gets per minute. I know my computer is stupid fast and my cpu will max out on one of the cores from certain profiles, *(Tara get rid of all that crap :D ) but that doesn’t mean anything when the status bar is “waiting for page” for about 30 seconds.

    I do understand what is “working” in the background of facebook and if you want to see your computer do the same thing, open up a search and look for ever *.ini file on your computer while you open MSPAINT and do a bucket fill with red on a file that is 40000×30000 pixels and try to open up your documents folder, see how long that takes on your 1000 dollar machine and imagine facebook is doing millions of millions of things like that per second and still doing it well 24hrs a day for a growing interconnecting everchanging mass of people.

    It’s great that we have these FREE services and no complain that there is a longer delay than usual. If you want to feel the real lag try dialing up to it :D

    Wayne M

  7. admin Says:

    Re:”why the hell did you compare facebook with google searching?”
    I was pre-empting the question “If Google can present a zillion search results in milliseconds, why does Facebook take so long to display a pretty profile?”
    Answer: Yes, facebook is another story completely

  8. Evgeny Says:

    You can’t expect facebook to load fast, because your browser makes about 100 requests for every page on facebook. Mostly because they have small javascript files and small stylesheet files that they dont concatenate into one bigger/versioned one … and that makes your browser to fetch each one separately. Each fetch like that makes the process very painfully slow. Does not really have much to do with the load on their server, considering the awful way they serve their pages - they are coping okay so far.

  9. steve Says:

    The multitude of css and javascript files are not from Facebook - they are from the thousands of poorly structured ad sites that are embedded into the pages - please facebook, only accept ads from sites with responsive servers.

  10. network geek Says:

    This pdf slideshow explains how the scaling solutions differ between ‘read sites’ and ‘write sites’ in the data persistence layer.

    http://www.cs.ait.ac.th/~mdailey/courseware/index.php?action=getlecture&course_id=6&lecture_id=8

    note the bit where its says….

    ..Computation scaling strategies..
    ..This means vertical scaling is best for the persistence layer in
    applications with a high transaction volume…
    …Vertical scaling replaces a single box with a bigger more expensive
    single box (more CPUs, disks, etc.)..

    Therefore, (accorsing to this) sites like facebook have to either spend lots of money to keep up with exapnsion or come up with genius ideas to circumvent the problems.

  11. Why? Says:

    Why is everyone so ‘argumentative’ in the first place? Admin, I give you credit for keeping your cool dispite ignorance!

  12. Hilliardman Says:

    Its the spam they are trying to load on each screen.

  13. Matt Leger Says:

    I think people arguing on the internet msg boards is possibly the most useless activity one can do. Unless someone learns something.

  14. admin Says:

    @ Why? - Thanks for the ‘keeping your cool’ support. But, I think that the tone of the post was a little bit inciteful so I see why it beckoned a blasting from the masses. I can handle it ;o)

    @Matt - Yes, you are right. If you look at the rest of my blog there are hardly any comments…i guess its because i rarely incite controversy. Any blogger/web author, has to admit that they secretly thrive on comments, (good or bad …as long as its not spam). It reminds me of the Argument Sketch from Monty Python : http://www.mindspring.com/~mfpatton/sketch.htm

  15. Charlotte Says:

    WHAt s that banskyfied google home page all about johnnie walker….it concerns me greatly, i might just have to take you up on the offer of a bit of up the avon in a bristol b&b, all expenses paid. bless you. x

  16. Laura Says:

    I think you’ll find Facebook is slow because of all these reasons! The ads they show are running all sorts of scripts which slows down the performance of Facebook. The servers probably cant hack all the updating and data retrieval as much as other sites and also Facebook is coded in PHP as well as being badly coded! This probably isnt doing anyone any favours, they need to re-code the whole darn site into ASP.net or something. Still we should be grateful it runs at all.

  17. Bobby Says:

    Uhhhh…how much does Facebook cost you? Exactly… Just be glad it is a free service. Stop uploading 10 million pictures of you flashing the peace sign and stop playing with your your Mafia, Farm, Fish, Dog,…apps. Too much unnecessary activity slows it down, so deal with it. I can’t even imagine how crazy the database back end gets when everyone and their mother is doing crazy stuff on FB.

  18. bobocat Says:

    Oh my god Bobby exactly my sentiments!!!!

Leave a Reply