U.S. stocks got back to their winning ways on Thursday, as the benchmark S&P 500 gained 0.2%, while the narrower Dow Jones Industrial Average (^DJI 0.56%) was unchanged. Apple's (AAPL -1.22%) performance today partially explains the discrepancy (Apple isn't a Dow component), as the stock rose 8.2% on better-than-expected results, and an augmented capital return program. That equates to nearly $40 billion tacked on to Apple's market value, putting it above the $500 billion mark. Apple's rise also contributed to a 0.5% gain in the technology-heavy Nasdaq Composite Index (^IXIC -2.05%), which has now clawed its way back to within 5% of its March 5 high. However, the focus this evening is two other technology heavyweights, Microsoft (MSFT -1.27%) and Amazon.com, which reported quarterly results after the closing bell.

Although analysts and financial journalists thought the current earnings season would be a stern test for companies -- and, by extension, the stock market --- Microsoft followed Apple in passing with flying colors. Their results provide a healthy tailwind as the major indexes appear to be on their way back up to their recent highs; after all, the two companies' combined market value is now almost $840 billion.

This was Satya Nadella's first quarterly-earnings report as Microsoft's new CEO, and his message on today's earnings conference call is clear: In the face of a dramatic shift toward mobile devices, Microsoft is no longer content to milk its traditional Windows and Office franchises. Microsoft must evolve, and the new watchwords are "mobile first, cloud first" ("cloud" refers to services that users access via the web], an expression Mr. Nadella repeated at least three times during the call. That means migrating Office users toward the web-based version, Office 365 (which operates on a subscription model), for example, or working with non-Microsoft devices such as the iPad.

On the numbers: Microsoft's $20.4 billion in revenue was essentially flat year on year, and in line with Wall Street's expectations. Earnings per share of $0.68 fell nearly 6% year on year, but, crucially, they were 8% above analysts' consensus estimate.

Devices and consumer revenue rose 12% (I was surprised to learn that the Surface tablet did a half-billion dollars in revenue); meanwhile commercial revenue -- the heart of Microsoft's fortress -- gained 7%, with Office 365 revenue more than doubling.

During the call, Mr. Nadella summed up the quarter with two words: execution and transition. Normally, I'd ignore this type of lingo from a chief executive; but, in this case, Nadella appears to be genuinely driving both of these. I've been very impressed with him in the short time since he has taken on the top role. He brings a fresh approach and energy to Microsoft that is in sharp contrast to his predecessor, Steve Ballmer.

In after-hours trading, Microsoft's stock was not much below its April 1 high. Valued at just 14.5 times next 12 months' earnings-per-share estimate as of today's close (that's less than the market's multiple), the stock looks reasonably well-positioned to deliver market-beating returns during the next several years.