Microsoft reported a better-than-expected quarterly profit as demand for its cloud computing services for companies rose and its personal computer software business stabilised.

The company’s focus on fast-growing cloud applications and platforms is helping combat slowing demand for personal computers that has hurt sales of Windows – the software that powered the company to the top in the 1990s.

Under chief executive Satya Nadella, Microsoft’s cloud business – which includes products such as Office 365, Dynamic 365 and the flagship Azure computing platform – has emerged as a major source of growth.

Amazon said its sales surged over the summer and its profit exceeded expectations, as shoppers jumped at “Prime Day” promotions on its website and in the US bought groceries at its newly acquired chain of Whole Foods Market stores.

Alphabet reported stronger-than-expected advertising sales and higher operating margins, driving shares up in after-hours trading as investors brushed off concerns about higher costs for acquiring mobile customers.

Twitter said it may become profitable for the first time next quarter after cutting expenses over the past year and doing deals to sell its data to other companies, which could help to break its reliance on advertising for revenue.

And Intel, the world’s largest computer chipmaker, raised its full-year revenue and profit forecasts, helped by strong growth in its data centre business.