Twitter is seething over the news that internet giants, including Google and Facebook, have been told to remove offensive content from the web following a court order from the Indian government. Some say that India is becoming a censored state, just like China. But the difference is, it has a vibrant and free media. So, why would a democracy like India pick a fight with the internet?

The simple answer might be that this is a state that has suffered religious violence in the past, and it's just trying to keep the peace by taking down some hateful material. It is the kind of censorship that, while not ideal for freedom for speech, quite a few Indians could buy into. Look a bit deeper, though, and the reality is more insidious. The loudest pro-censorship calls among politicians seem to be reserved for websites that are about them. Their aim appears to be not just to censor the dangerous stuff, but to polish the government's image, too.

India has a long and healthy tradition of satire, which has unsurprisingly found a home on the web, with bloggers and tweeters keeping a cheeky check on the antics of the powerful. But in December, communications minister Kapil Sibal began voicing concerns about the "defamation" of political leaders online, including fake pictures of the president of the Congress party, Sonia Gandhi, and the prime minister, Manmohan Singh, in compromising positions. One shows their faces plastered onto a painting of the Madonna and child, while another has Singh dancing on a string for Gandhi like a performing monkey. If censorship of religious hate material continues, these are exactly the kind of images that might be removed next.

Dirty jokes are rarely good grounds for censorship, but they're even worse when the public feels the government is itself far from clean. The gag that all politicians are crooks takes on a whole new meaning in India: a report at the end of last year by National Election Watch and the Association for Democratic Reforms, based in New Delhi, found that 162 MPs in the lower house of parliament had pending criminal cases, 76 of them serious. And aside from the crimes, there's also the corruption – which is so bad that last summer saw countrywide protests to force the government to clean up its act and stop politicians from creaming off money from public projects.

Keeping up with politicians' antics is a full-time job for the Indian media. Fortunately, they do it pretty well. In 2010, for example, when the chief minister of Uttar Pradesh was snapped with a hefty garland of high-value banknotes around her neck – a gift from her supporters – newspapers reprinted and commented on the photo widely. Most politicians understand that taking on the domestic press is dangerous; the public deeply values independent papers and news channels, and treats the most courageous journalists as national heroes.

But internet users are the ones scrutinising every fact and leeching out the maximum satirical value from the news. One filmmaker, for example, was inspired to post a music video about the Mayawati garland.

The problem is, unlike the domestic media, internet companies are fairly easy pickings. Should they cross the line, they can be banned – instantly losing out on one of Asia's biggest and most lucrative markets. The equation is simple, and everyone knows it: Google is more likely to kowtow to the government than risk abandoning a cash cow like India. Taking down a few objectionable web pages now is the rational economic choice.

In the future, though, the fat end of this wedge risks doing serious damage to India's democracy. Censorship is an especially vicious kick in the teeth to those who have risked everything to fight for freedom of speech: according to the Committee to Protect Journalists, 16 journalists have been murdered in India since 1992, more than two-thirds of them while covering the political or corruption beats. They were willing to put their lives on the line. Google, Facebook, Twitter … what are you willing to do?