The movie was released in 2010 and had to have started being planned for at least 1-2 years before that. It seems this was incredibly fast after Facebook was released to the whole world and took off. What is the reason for this?
In some ways, asking "what's the reason for this" might be a non-starter of a question, because the ultimate reason for why any movie is made is that a producer thinks it's a good idea. And certainly, the fact that Facebook was made open to everyone late in 2006 makes it seem like the time frame is pretty compressed to get the movie out, but it's important to remember that Facebook had been around for several years before that -- every college kid in the US knew about it by late 2004. So even if Sorkin started his research in 2008, that's 4 years after it became clear that this could be a good story, far less time than it took for Zero Dark Thirty to be released and pretty comparable to United 93.
I think it's also important to note that Sorkin (and Sony Pictures who produced it) didn't come up with the idea; rather, the publisher of the book The Accidental Billionaires was actively selling the film rights before the book ever came out. According to an interview that Sorkin gave:
As we already know that 'The Social Network' was based on a book called 'The Accidental Billionaires' by Ben Mezrich. Now if you check the wikipedia entry it tells us something about the production.
So it's like the book and the screenplay for this movie were almost written in parallel.
So when the book was released in 2009, pretty soon the movie als got released in 2010. So my point is - The Social Network's production just followed the production of the book - The Accidental Billionaires. And the book followed what was an interesting story at that time. So it is only coincidental that the movie's release and facebook's boom occured at the same time.