Microsoft chief executive Satya Nadella speaks during a fireside chat at the Tsinghua Management School in China on June 1, 2016.

Microsoft is successful around the world in large part because it gives back to local communities and creates lots of businesses there, CEO Satya Nadella told financial analysts on Wednesday.

Microsoft operates in more than 190 countries, and Nadella said the ability to compete in so many places is vital to the company's "overall long-term growth." But you can't just set up shop and give nothing back -- you have to "create local opportunity."

This is especially true in the current age, as politicians and citizens in many countries are turning against the decades-long trend of globalization.

"Every head of state only cares about one thing: it's about their country first," said Nadella. "In the U.S. it's about America first, and in Britain it's about Britain first."

When talking to these heads of state, a company must to be able to show them what you've done for their countries "in terms of local taxes, in terms of local small business productivity, local large business competitiveness, their educational outcomes, their entrepreneurial work, that's what matters," he said.

"Any company that just collects rent internationally," Nadella added, "will be in trouble."

Microsoft booked more revenue from outside the United States than from within it in each of its last two fiscal years. In the fiscal year ended June 30, 2016, it generated $44.7 billion in international sales, versus $40.6 billion domestically.