They provide massive storefront and app hosting bandwidth. The Facebook app is 296.3 MB according to the App Store, and that app sometimes has multiple updates a week.
Supposedly 80% of Facebook users access the service exclusively from the mobile app. Even with compressed deltas this is a monstrous amount of data transfer.
Facebook has over two billion active monthly users of their mobile apps based on that 80% stat above. Even if they got 90% compressed deltas for updates, my napkin math says two billion users at 6 updates a month of a 300 MB app would still be on the order of hundreds of petabytes of data a month.
It's not hosting. Its a marketplace.
They provide technical services like hosting and SDKs for sure, but they created a marketplace. If you go into a retail store and someone is trying to sell you to switch your phone provider or internet provider, you better believe that retail store is getting a cut of that service revenue. In fact, I've heard some telcos have been willing to go break-even for the first year for long-term customer acquisitions.
It's funny we never hear people talking about Google's trillion dollar valuation and ad business and say "I don't get how they justify charging so much - they are charging me tens of thousands of dollars just injecting my ad copy into search results and web pages. I could do that with perl."