Major authors from Arundhati Roy to William Dalrymple and Neil Gaiman have condemned Penguin's controversial removal of Wendy Doniger's book The Hindus from circulation in India, a withdrawal which has been described as an "egregious violation of free speech" and "deplorable" by the international literary community.

The decision is "shocking, appalling, dreadful and entirely negative," Dalrymple told the Guardian, while Roy, the Booker prize-winning author of The God of Small Things, has called on Penguin to explain why it "caved in". Doniger's widely praised book was pulled from India following a lawsuit from the Hindu group Shiksha Bachao Andolan accusing the University of Chicago professor of "hurt[ing] the religious feelings of millions of Hindus" – a violation of the Indian penal code which prohibits "deliberate and malicious acts intended to outrage religious feelings or any class by insulting its religion or religious beliefs". The lawsuit, which also says Doniger's book is "a shallow, distorted and non-serious presentation of Hinduism" which is "riddled with heresies and factual inaccuracies", has been played out over the last four years, and according to the petitioner's lawyer, earlier this week publisher Penguin agreed to withdraw the book, and to pulp copies.

The move immediately triggered an avalanche of protest. The Indian branch of writers' organisation PEN said that "choosing to settle the matter out of court, instead of challenging an adverse judgment, narrows India's intellectual discourse and significantly undermines freedom of expression", adding: "The removal of books from our bookshops, bookshelves, and libraries, whether through state-sanctioned censorship, private vigilante action, or publisher capitulation are all egregious violations of free speech that we shall oppose in all forms at all times."

In an open letter to Penguin India – her own publisher – published in the Times of India, Roy predicted there would "soon no doubt be protesters gathered outside your office, expressing their dismay" at the pulping of The Hindus.

She asked Penguin – which has yet to respond to requests for comment on its decision – "what is it that scared you so", adding: "What are we to make of this? Must we now write only pro-Hindutva books? Or risk being pulled off the bookshelves … and pulped?"

"You have published some of the greatest writers in history," wrote Roy. "You have stood by them as publishers should, you have fought for free speech against the most violent and terrifying odds. And now, even though there was no fatwa, no ban, not even a court order, you have not only caved in, you have humiliated yourself abjectly before a fly-by-night outfit by signing settlement. Why? You have all the resources anybody could possibly need to fight a legal battle. Had you stood your ground, you would have had the weight of enlightened public opinion behind you, and the support of most – if not all – of your writers."

In the US, the National Book Critics Circle – which had shortlisted The Hindus for its prestigious non-fiction award in 2009 - called on Penguin to reverse its "deplorable decision to remove The Hindus from circulation in the country, a de facto act of self-censorship that will only contribute to a further rolling back of free speech in India".

In a statement, Doniger herself said she was "angry and disappointed" at the situation, and "deeply troubled by what it foretells for free speech in India in the present, and steadily worsening, political climate".

But the author expressly said she did not blame Penguin Books India, saying they took the title on "knowing that it would stir anger in the Hindutva ranks, and they defended it in the courts for four years, both as a civil and as a criminal suit".

"They were finally defeated by the true villain of this piece – the Indian law that makes it a criminal rather than civil offence to publish a book that offends any Hindu, a law that jeopardises the physical safety of any publisher, no matter how ludicrous the accusation brought against a book," said Doniger, pointing to a quote from the lawsuit in which she is accused of hurting "the religious feelings of millions of Hindus by declaring that Ramayana is a fiction".

The historian Dalrymple agreed, saying the "real villains are the laws in this country, which were old colonial laws drawn up in the 1890s, and which make insulting religion a criminal offence".

"They give the general impression we are in 1936 in Germany, with freedoms being curtailed on a daily basis," said Dalrymple, author of Nine Lives: In Search of the Sacred in Modern India, The Last Mughal, and White Mughals. "The reality is that it is very difficult to defend yourself because the law is stacked very heavily on the side of any lunatic. It's shocking, appalling, dreadful and entirely negative, but I can understand why Penguin did what it did. They should have defended it, but I can understand why, with the law as it is, they decided they couldn't win the case."

Hari Kunzru: condemned 'the saffron offence machine'. Photograph: Murdo Macleod

Novelist Hari Kunzru joined the chorus of outrage, saying: "The Hindu far right … has become expert in wielding the weapon of offence to silence critics. India looks set to elect Narendra Modi, who was quick to ban a recent biography of Mahatma Gandhi in his home state of Gujarat. Once he's in power, I fear the saffron offence machine will reign unchecked, and it will be very difficult for scholars, writers and artists to defend themselves."

PEN India pointed to other titles which have been suppressed in the country, saying that "Indian publishers have faced waves of threats from litigants, vigilante groups, and politicians". Siddhartha Deb's The Beautiful and the Damned was published without its first chapter because of a lawsuit, according to PEN, while Bloomsbury India withdrew from circulation Jitender Bhargava's book, The Descent of Air India.

"Sahara Group is suing Tamal Bandyopadhyay, author of Sahara: The Untold Story," said PEN India, and "foreign publishers have not distributed an English translation of The Red Saree, a book loosely based on Sonia Gandhi's life".

Dalrymple urged those who disagree with the pulling of The Hindus to "form a movement to change the law", while Doniger pointed out that "in the age of the internet, it is no longer possible to suppress a book. The Hindus is available on Kindle; and if legal means of publication fail, the internet has other ways of keeping books in circulation. People in India will always be able to read books of all sorts, including some that may offend some Hindus."

The withdrawal has already sent The Hindus: An Alternative History soaring up the bestseller charts, a consequence which "may not have been the outcome that the people who tried to get it suppressed had hoped for," according to the novelist Neil Gaiman.

"The solution to a book you don't like is to explain why you don't like it, point out its flaws, write your own book," said Gaiman on his blog. "It's not to get the book pulped because it offends you. even if you think it's bad. Especially if you think it's bad."