Twitter has refined its technology so it can censor messages on a country-by-country basis.

The additional flexibility announced on Thursday is likely to raise fears that Twitter's commitment to free speech may be weakening as the short-messaging company expands into new countries in an attempt to broaden its audience and make more money.

But Twitter sees the censorship tool as a way to ensure individual messages, or tweets, remain available to as many people as possible while it navigates a gauntlet of different laws around the world.

Before, when Twitter erased a tweet it disappeared throughout the world. Now, a tweet containing content breaking a law in one country can be taken down there and still be seen elsewhere.

Twitter will post a censorship notice whenever a tweet is removed. That is similar to what internet search engine Google has been doing for years when a law in a country where its service operates requires a search result to be removed.

Like Google, Twitter also plans to the share the removal requests it receives from governments, companies and individuals at the chillingeffects.org website.

The similarity to Google's policy is not coincidental. Twitter's general counsel is Alexander Macgillivray, who helped Google draw up its censorship policies while he was working at that company.

"One of our core values as a company is to defend and respect each user's voice," Twitter wrote in a blogpost. "We try to keep content up wherever and whenever we can, and we will be transparent with users when we can't. The tweets must continue to flow."

Twitter, which is based in San Francisco, is tweaking its approach now that its nearly six-year-old service has established itself as one of the world's most powerful megaphones. Daisy chains of tweets already have played instrumental roles in political protests throughout the world, most notably in the uprising that overthrew Egypt's government a year ago.

It's a role that Twitter has embraced, but the company came up with the filtering technology in recognition that it will likely be forced to censor more tweets as it pursues an ambitious agenda. Among other things, Twitter wants to expand its audience from about 100 million active uses to more than 1 billion.

Reaching that goal will require expanding into more countries, which will mean Twitter will be more likely to have to submit to laws that run counter to the free-expression protections guaranteed under the first amendment in the US.

If Twitter defies a law in a country where it has employees, those people could be arrested. That's one reason Twitter is unlikely to try to enter China, where its service is blocked. For several years Google agreed to censor its search results in China to gain better access to the country's vast population, but stopped that practice two years after engaging in a high-profile showdown with Chain's government. Google now routes its Chinese search results through Hong Kong, where the censorship rules are less restrictive.

In its Thursday blogpost, Twitter said it had not yet used its ability to wipe out tweets in an individual country. All the tweets it has previously censored were wiped out throughout the world. Most of those included links to child pornography.