Efforts by countries like China to restrict the exchange of information on the internet are ultimately doomed to failure, Microsoft chairman Bill Gates told an audience of Stanford University students Tuesday.

"I don't see any risk in the world at large that someone will restrict free content flow on the internet," he said. "You cannot control the internet."

China has grappled with the issue of internet censorship in recent years and Microsoft, along with several other US companies, has come under fire for aiding in this effort. In late 2005, Microsoft shut down the blog of journalist Zhao Jing, also known as Michael Anti, when he blogged about a newspaper strike in the country.

In the long run, however, free speech will win out, Gates said.

That's because of business requirements. Restrictions on free speech will curtail business activity and so commercial forces will work against censorship, Gates said. "If your country wants to have a developed economy... you basically have to open up the internet," he said.

Gates made the comments following a talk on "Software, Innovation, Entrepreneurship and Giving Back," which focused mainly on his two favorite topics: the future of technology and the philanthropic goals he has set for himself following his retirement from day to day work at the company he founded in 1975.

Microsoft's founder will step down from his daily work at the company entirely in July, but he has set some big follow-up goals for himself, including the fight against HIV/AIDS and a campaign to eradicate polio and malaria.

Another ambition is to find new ways to drive innovation that will benefit the world's poorest countries.

This is a major problem, Gates said. Today, with millions still dying from malaria, 90 per cent of the world's medical research relates to conditions that occur in the world's richest countries. "Consider how much money should be spent on baldness versus malaria," he said.

Fifty times the amount spent on researching malaria goes to finding a cure for baldness, he said.

"We have this disparity where, as great as our system is, if there's not a market need, it doesn't drive innovation."

Gates would like to see that change.

"One of the things I'll be spending time on is reaching out to both universities and companies and encouraging them to get more involved in this," he said.

The 52 year-old Gates seemed apprehensive about his upcoming career as a philanthropist. Stepping down from Microsoft "could be traumatic for me," he said. "I was 17 years old when I started working full-time on Microsoft and I've done it basically every day of work since then. So who knows what it will be like to make the change."