The flames leaping above the towers of Notre Dame Cathedral, as crowds of dazed onlookers sung hymns in the twilight, looked apocalyptic, a sight from the end of days – or at least the climactic scene of a Dan Brown novel. The destruction of a building so iconic, so symbolic of a nation, is deeply unsettling. And so it should be, for this irreplaceable loss of 800-year-old heritage is tragic. But setting the calamity in historical context shows us how unusual our age is in investing so greatly in the veneration of ancient buildings – and how accustomed we have become to thinking they can be frozen in time.

Happily, Notre Dame seems to have emerged less ravaged than was initially feared. The main fabric of the church has survived, and the relics and other holy items inside were, largely, rescued. It was easy to forget as smoke and flame belched heavenwards that the roof, made from a forest’s worth of medieval timber, was separated from the interior by the high, arching stone vaults. Some of those have collapsed, but most seem still in place. The glorious stained-glass rose windows, dating from the 13th century (when the cathedral was completed), have been mercifully spared too.

Notre Dame is one of the most celebrated high-gothic cathedrals, which are surely among the most astonishing architectural achievements of all time. They embody both the technical skill and the philosophical and theological profundity of the unjustly vilified middle ages: a time that saw the first dawn of a faith in an orderly universe, which led eventually to the emergence of science. But this aesthetic judgment is relatively modern. “Gothic” was a derogatory term when coined originally in the Renaissance: the Italian writer Giorgio Vasari used it to contrast the supposed barbarism of that earlier time (anachronistically linked to the Goths, who sacked Rome) with the splendours of his own age. The English diarist John Evelyn dismissed gothic churches as “heavy, dark, melancholy, monkish piles”.

This video has been removed. This could be because it launched early, our rights have expired, there was a legal issue, or for another reason. Drone footage shows Notre Dame Cathedral fire damage – video

Even in their heyday there was nothing sacred about their original design. Bishops would look at their cathedrals and fret over how old fashioned they seemed, merrily commissioning new wings, towers, windows and annexes to bring them up to date. The result is often an awkward clash of styles and structures from different times.

During the baroque period, many of these churches were blighted by kitsch makeovers. At Notre Dame, marble statuary glorifying the Bourbon kings was plonked in place of the medieval high altar. Even worse followed in the revolution: Notre Dame was ransacked as metal bells, grilles and reliquaries were melted down to make cannons and the cathedral was used as a warehouse. It was in a sorry state when Napoleon Bonaparte revitalised its image by being crowned emperor there in 1804.

Gothic architecture became respected only in the 19th century, when the French architect Eugène Viollet-le-Duc spearheaded the gothic revival and Victor Hugo made Notre Dame emblematic as the haunt of his hunchback hero. Hugo’s 1831 book, called in French simply Notre-Dame de Paris, popularised the romantic idea that the gothic cathedrals were created not by the priesthood but by the people, inspiring Viollet-le-Duc to see them as symbols of French unity. He meant well, but by today’s standards he took liberties with his heavy-handed “restoration”, which included the fantastical Alice-in-Wonderland gargoyles of Notre Dame. What has come down to us in the gothic cathedrals is, then, often a jumbled patchwork of styles and underlying philosophies.

France is a divided nation – but Notre Dame has brought us together | Marion Van Renterghem Read more

What’s more, centuries ago, decay and destruction could be almost taken for granted by the devout. The very reason we have many of these wonderful buildings at all is because fire made way for them. That is how we got Chartres Cathedral, after a fire in 1194 destroyed the building commissioned in the 1020s. The conflagration devastated the morale of the local people: a document written in 1210 says they “considered as the totality of their misfortune the fact that they, unhappy wretches, in justice for their own sins, had lost the palace of the Blessed Virgin, the special glory of the city, the showpiece of the entire region, the incomparable house of prayer”. Yet they soon put a positive spin on the reconstruction. Another early 13th-century account asserted that this was the Virgin’s will all along: “She therefore permitted the old and inadequate church to become the victim of the flames, thus making room for the present basilica, which has no equal throughout the entire world.” It was a holy miracle. (Headlines about the survival of Notre Dame show that little has changed.)

And so it went on throughout the middle ages and beyond: the great edifices of the gothic master-builders fell or burned down, were neglected or dismembered, suffered undignified “improvements”. Chartres lost its medieval roof to fire in 1836, and no one seems too bothered now that today’s replacement was intended only to be temporary.

As the damage to Notre Dame is repaired, we should remember that these magnificent buildings have always been works in progress. Perhaps, in mourning what was lost, we can take the opportunity to marvel again at the worldview that produced it: at the ambition, the imagination, the profound union of technical skill and spiritual conviction. And we can consider it a worthy challenge to see if we can find some way of matching and honouring that vision.

• Philip Ball is a science writer