For many in the expanding Hindu middle class – demoralised for decades by Congress’s betrayals and being rapidly unshackled, by [Manmohan] Singh’s liberal economic policies, from Nehruvian shibboleths about self-restraint – the barbarism in Ayodhya contained a self-empowering, even redemptive, message: an ancient civilisation had purged itself of the shame inflicted by history by razing the monument to its subjugation. The past, so many felt, had been avenged.

The promise of a violent release for the resentments and confusions incubated by Hindus’ unresolved feelings about their history is what gave Hindu nationalism its visceral appeal. The anti-colonial nationalism pioneered by Congress, cohering in opposition to the British, had applied a romantic gloss on pre-colonial India: it was Eden vandalised by satanic Europeans. But had the British really ruptured India’s historic continuity? Or was it India’s decline, precipitated by centuries of conquest, that enabled Britain so swiftly to overpower the subcontinent?

The conceit of the freedom movement led by Congress was that a fully developed national consciousness existed in the subcontinent before the British arrived, smashed it and divided the natives.

Singling the British out as uniquely disruptive villains proved a convenient way for republican India’s secular intellectuals to bypass awkward questions that ought, in the long-term interests of the country, to have been confronted head on. The airbrushing of the pre-colonial past was intended to deny ammunition to all those who cited the creation of Pakistan to intensify their clamour for a Hindu rashtra.

Historiographers tasked by the secular Congress establishment to clarify India’s past, motivated by the desire to do good, caused immeasurable harm by blurring it. They applied recondite techniques and treatments to source material, ladled their prose with jargon and, lost in disciplinary sport, neglected the needs of the lay persons outside the priesthood. Students emerged from exposure to their output without a rudimental apprehension of their difficult past. Medieval India, despite all the evidence of its methodical disfigurement, was depicted in schoolbooks as an idyll where Muslims and Hindus coexisted in harmony and forged an inclusive idea of India which the British came and shattered.

This fable was so wholly internalised by the secular establishment which dispensed it that, as late as 1998, KR Narayanan, India’s first Dalit president, was able to tell an audience in Turkey that the most “amazing fact” about his homeland before it was defiled by “European intrusion” was “that the interaction between the old civilisation of India – the Hindu civilisation – and the Islamic civilisation was a friendly experience”.

Such a thesis was always going to struggle against the overwhelmingly contradictive evidence – from the ruins of Hindu liturgical buildings to the ballads of dispossession passed from generation to generation – arrayed against it.

The chronicles of the subcontinent’s medieval rulers are full of pornographic descriptions of the horrors with which the place teemed. Here is the Persian historian Vassaf relating with elation the reduction of Cambay in Gujarat by the forces of Alauddin Khilji:

The Muhammadan forces began to kill and slaughter on the right and on the left unmercifully, through the impure land, for the sake of Islam, and blood owed in torrents. They plundered gold and silver to an extent greater than can be conceived...They took captive a great number of handsome and elegant maidens, amounting to 20,000, and children of both sexes, more than the pen can enumerate...In short, the Muhammadan army brought the country to utter ruin, and destroyed the lives of the inhabitants, and plundered the cities, and captured their offspring, so that many temples were deserted and the idols were broken and trodden under foot, the largest of which was one called Somnat, fixed upon stone, polished like a mirror, of charming shape and admirable workmanship. The Muhammadan soldiers plundered all those jewels and rapidly set themselves to demolish the idol. The surviving infidels were deeply affected with grief, and they engaged to pay a thousand pieces of gold as ransom for the idol, but they were indignantly rejected, and the idol was destroyed, and its limbs, which were anointed with ambergris and perfumed, were cut off. The fragments were conveyed to Delhi, and the entrance of the Jama Masjid was paved with them, that people might remember and talk of this brilliant victory. “Praise be to God, the Lord of the worlds, Amen!”

The general retort of the “secular” historian confronted with writings of this vein tended to be that they were an exaggeration meant to impress the rulers – without any meditation on the nature of the rulers who might be flattered by such graphic descriptions of gore staged in their name – or to read into them motives the text did not support, or to discredit them as British propaganda. Unfortunately for them – and for the national project they were serving – the grand mosques of northern India are decorated with stone tablets in which you can still see traces of the pre-existing liturgical monuments that were razed to furnish the building materials for them.

But pick up a history textbook taught at state institutions and you will find no explanation of what happened. It was the mission of “secular” historians and public intellectuals of India to locate mundane causes for carnage by religious zealots.

And when those reasons could not be found, they papered over the gruesome deeds of the invaders with nice-nellyisms and emphasised their good traits. A standard history textbook written for Indian schoolchildren by Romila Thapar follows up the admission that the Ghaznavid ruler Mahmud was “destructive in India” – a phrase that omits so much – with the mitigation that “in his own country he was responsible for building a beautiful mosque and a large library”.

All imperialism is vicious, but that is not the standard adopted by India’s secular historians. The Portuguese, the same textbook tells us, “were intolerant of the existing religions of India and did not hesitate to force people to become Christian”. Indeed, they “did all that they could to make more converts”. On the other hand, Islamic invaders, in a sentence that catches the breath if only because of its contrast with the candid assessment of the Portuguese, “did not produce any fundamental change in Indian society but they did help to enrich Indian culture”. Babur, the founder of the Mughal empire whose campaigns made Portuguese pacification look like a picnic, “enjoyed playing polo”. Imperialism, in other words, was destructive only when Europeans did it. When Asians did it, it was a cultural exchange programme.

Such well-intentioned sanitisation of the past was never, in the long run, going to be able to withstand the awakening of people to their history or sustain an inclusive nationalism. The encounter between “the strictest and most extreme form of monotheism” and “the richest and most varied polytheism”, Octavio Paz wrote in his luminous study of India, left a “deep wound” on the psyche of its people.

The secular establishment squandered a rare opening in the early decades of the republic to heal that wound by supplying Indians a forthright accounting of their history. Had India been honest about its past – about the atrocities that were perpetrated and the heritage that was ravaged – it might have desiccated the appeal of Hindu supremacism.

It might have reconciled Indians to their harrowing past, provoked a mature detachment from it and denied Hindu nationalists the opportunity to weaponise history. To come to terms with the past, to move on from it, we must first acknowledge and accept it. A thousand years of Indian history were obfuscated. The reasons were lofty; the consequences of the well-meaning distortions, alas, baleful. Secularists endangered the extraordinary religio-cultural synthesis India arrived at by airbrushing its unbeautiful genesis. No Indian individual or community bears any responsibility for what happened in the pre-colonial era. By downplaying and denying what happened, secularists unwittingly implied otherwise.

Excerpted with permission from Malevolent Republic: A Short History of the New India, KS Komireddi, Context.