Nothing lasts forever: if history has any lesson for us, it is this. It's a thought that comes from rereading Paul Kennedy's magisterial tome, The Rise and Fall of the Great Powers, in which he shows that none of the great nation-states or empires of history – Rome; imperial Spain in 1600; France in either its Bourbon or Bonapartist manifestations; the Dutch republic in 1700; Britain in its imperial glory – succeeded in maintaining its global ascendancy for long.

What has this got to do with technology? Well, it provides us with a useful way of thinking about two of the tech world's great powers. The first is Apple. The past week saw a veritable torrent of hysterical reaction to its quarterly results, coupled with fevered speculation about its future. The globe has been hypnotised for years by Apple's metamorphosis from a failing computer manufacturer into a corporate giant that, on some days, is now the most valuable company in the world, with bigger cash reserves than the annual GDP of some countries. But as with all inexorable growth curves, the question on every commentator's lips is: has Apple peaked?

If you think "hysterical" is a bit harsh, then ponder this. Although Apple did not sell the 50m iPhones that had been forecast for the quarter (it "only" shifted 47.8m) and sales of its Mac computers were down somewhat, nevertheless the quarterly results mean that in 2012 Apple earned more in the year than any other corporation, ever. And even the quarter's supposedly disappointing earnings of $13.1bn were the fourth largest of all time, according to the same metric. And the reaction of the stock market to this news? The share price dropped 10% in after-hours trading.

Then there's the social network Facebook with its billion users, which is likewise the focus of much hyperventilating comment. Recently, the Mark Zuckerberg empire launched its latest deadly weapon with the catchy name of Graph Search – as in "social graph". Facebook's new tool is just an algorithm that finds information from within one's network of friends and supplements the results with hits from Microsoft's Bing search engine, but to read some of the commentary on it you'd think that Zuckerberg & co had invented either a perpetual motion machine or a through-ticket to hell.

"Facebook's new search engine attempts to build walls around the internet and keep its horde within its gates," wrote the webmaster of a respected online magazine. "It's a nightmare and it will probably work."

Actually, it's Facebook's latest attempt to become the AOL de nos jours. And, in the end, it will fail for the same reason that AOL's attempt to corral users within its walled garden failed: the wider internet is just too diverse, innovative and interesting. But because Facebook looms so large in the public consciousness at the moment, it's difficult to keep it in perspective. Which is why Kennedy's book makes such salutary reading.

So what we need to remember as we wade through the current overheated commentary on Apple and Facebook is that nothing lasts forever. I have been in this racket long enough to remember a time when Microsoft was at least as dominant and scary as these two companies are now. Spool forward a couple of decades and Microsoft is still around, but actually it's an ailing giant – profitable but no longer innovative, trying (and so far failing) to get a foothold in the post-PC, mobile, cloud-based world.

Although the eclipsing of Apple and Facebook is inevitable, the timing and causes of their eventual declines will differ. Apple's current strength is that it actually makes things that people are desperate to buy and on which the company makes huge margins. The inexorable logic of the hardware business is that those margins will decline as the competition increases, so Apple will become less profitable over the longer term. What will determine its future is whether it can come up with new, market-creating products such as the iPod, iPhone and iPad.

Facebook, on the other hand, makes nothing. It just provides an online service that, for the moment, people seem to value. But in order to make money out of those users and satisfy the denizens of Wall Street, it has to become ever more intrusive and manipulative. It's condemned, in other words, to intrusive overstretch. Which is why, in the end, it will become a footnote in the history of the internet. Just like Microsoft, in fact. Sic transit gloria.