The company forecast revenue in its main segments for the current quarter would match or top Wall Street targets.
Those results and Microsoft's helped boost shares of Amazon.com Inc (AMZN.O), another major cloud operator, 4.8% in after hours trading.
Microsoft revenue rose 7% to $52.9 billion in the quarter ended March, inching past analyst estimates of $51.02 billion, according to Refinitiv.
The bulk of Microsoft sales still come from selling software and cloud computing services to customers.
The sales drop in the segment was less severe than analysts expected, with Microsoft reporting revenue of $13.3 billion versus analyst estimates of $12.19 billion, according to Refinitiv data.