Google should carry out its threat to withdraw from China. The US search giant says a cyber-attack on its intellectual property, and attempts to access email data from human rights activists, have driven it to the edge. From now on, it's no censorship, or no Google. Ditching the world's biggest group of web surfers makes a powerful statement about free speech - but could be good for business too.

It's easy to be cynical about Google's feisty tone. After all, the company has been willing to trim edit search results in China for three years to placate Beijing. And despite its don't be evil corporate mantra, Google's shareholders have gone along with voluntary censorship. It seems the final straw wasn't principle, but property - the apparent theft of the algorithms Google uses to generate its search results.

But Google's anger does highlight a real problem. Internet censorship in China is getting worse. Curbs range from the sinister to the ridiculous. Many web cafés have live video links to police stations; college students can win cash prizes in porn-hunting competitions. China's farcical adult content filtering software, Green Dam, blocked pictures of cartoon cat Garfield and roast pork, but allowed some nudity to sail right through.

Google isn't yet making money in China, say people familiar with the situation. And investors probably weren't pricing in much potential. China's market leader, Baidu, has a market capitalisation of just $14 billion - less than a tenth of Google's. Still, exiting China will not be painless. Internet ad spending is set to more than double by 2012, according to Credit Suisse. The country's internet users outnumber the population of the US.

The pain is probably worth it. Quitting China would restore the ethical credentials Google compromised at Beijing's behest. That will surely win it more fans elsewhere, and not just among users. French leader Nicolas Sarkozy, who angered China's leaders when he met the Dalai Lama, has already attacked Google for market dominance. The bigger it gets, the more Google depends on political goodwill to keep making money. Being principled in China may pay dividends in the West.