Few foreign reporters were left in Santiago on the spring morning of Tuesday 11 September 1973 when Augusto Pinochet, head of the army, was pulling off his trick.

The previous Saturday he had finally joined in preparations for the long brewing coup d'état against a fairly elected government and, only three days later, was revealing his capacity for terrorism, torture and treason with a foreign power. Only now was he throwing in his lot with a US government that detested the idealistic but ramshackle coalition of six parties headed by Dr Salvador Allende, the country doctor and upstanding freemason who was set on introducing elements of social democracy in a country long organised for the benefit of the landowners, industrialists and money men.

For months the original plotters had kept Pinochet at a distance, judging him too loyal to the elected – and, as the results of the recent local elections showed, increasingly popular – Allende, and too loyal to the constitution to be allowed into the conspiracy.

Most foreign journalists had given up and left Chile after weeks of waiting, many returning from deprived and poor Santiago – proud but provincial – to bustling Buenos Aires and their homes across the Andes. The Washington Post had a correspondent, but not the New York Times; Newsweek, but not Time magazine.

As troops fanned out in the town awaiting the arrival of Hawker Hunter jets to bomb and destroy civilian government, Allende desperately but vainly tried to contact Pinochet and for a few hours was convinced that his military commander had been kidnapped and silenced by the insurgents.

Many of we foreign reporters in the weeks before September 1973 had got into the habit of gathering in the snug downstairs bar of the Carrera hotel – across the square from Allende's sober and unadorned presidential palace, the Moneda – where many of us were staying. Endlessly, over scotches and pisco sours, we tossed about our conjectures for the future, those with US passports rightly forecasting the worst for Chile's "socialist experiment".

On Tuesday, the counter-revolution was in full flood, telephone and telex lines were cut and the airports closed. Before 10am my friend and colleague, Stewart Russell of Reuters, and I trekked through deserted streets to the British embassy, above the Bank of London and South America, in search of a line that would take our story to London. No line was available but, as the firing in the streets increased, we were given house room and refreshments and could not but observe the unalloyed joy of many in the embassy, notably the British naval representatives, at the coup.

At that time Admiral Gustavo Carvajal, one of the plotters, was on the phone to Allende offering him a plane if he would leave the country. But the president, a man with high blood pressure, was trenchant: "Who do you think you are, you treacherous shits? Stuff your plane up your arses! You are talking to the president of the republic! And the president elected by the people doesn't surrender."

On the roof of our building a resister with a .22 rifle loosed off the occasional shot until he was killed by a passing helicopter. By four in the afternoon the city, ringed by its Andean peaks, was quieter, so Stewart and I, robbed of connections with London, marched out of the bronze doors down the centre of the deserted streets to our hotels, our hands in the air.

Back within the well-shuttered Carrera and gathering in its imposing reception area sheathed in black glass, Pinochet's many moneyed supporters toasted him with champagne, and his three fellow members of the junta from the navy, air force and gendarmerie. They whooped as he announced on television the closing down of congress, the political parties, the trade unions and the judges.

The terrified staff gathered in a corner and watched their country's fate being played out. As a precaution, for our safety, they had prepared beds for us past the laundry in the hotel's sub-basement. After a good night's sleep we emerged to watch the flames continuing to consume the Moneda. Under curfew the stadium began filling with Pinochet's prisoners: some were summarily shot, others were sent to concentration camps in the Atacama deserts of the north or the frigid sub-Antarctic south. At the beginning, when the curfew was clamped down at 6pm, there was a nightly rush for transport, public and private, as people scrambled to get indoors promptly.

The soldiers were initially frightening with their battledress and machine guns as they blundered in, messed up the houses of suspects and carried off whatever took their fancy. Foreigners who were fleeing persecution – in Brazil, for instance – and who had been given political asylum by Allende were in particular danger, as were office holders in the trade unions. Later on, the squaddies, many of them country boys, came to be seen as figures of fun as they took the presence of books on cubism, for instance, as evidence that the householder was an admirer of Fidel Castro and thus worthy of being arrested and interrogated. Comedians on television joked nervously about stupid people being as thick as a soldier without a car.

A rash of denunciations saw many imprisoned unjustly by the military, who would seldom confess who they had in prison and who they didn't. Over the weeks at the Moneda the flames consumed what they could, leaving a thick layer of ash.

Thus had started 17 years of Pinochet's dictatorship – he soon reduced his fellow members of the junta to a cipher – held together by terrorism. As had already been the case after the military coups in Brazil in 1964 and then in Uruguay, Paraguay, Bolivia and Argentina, and as was to be the case latterly in modern Iraq, Afghanistan and Guantánamo Bay, the military and police torturers were ready with their electrodes, thumbscrews and waterboarding equipment to defend "western Christian civilisation". Many had been brought to a peak of perfection in their trade in the US itself or in its bases in the Panama canal zone by US instructors.

Seven years before, at a dinner party in 1966 during a prolonged stay in the Chilean capital with my wife Georgie, I met Allende and his wife Hortensia "Tencha" for the first time. He and I got on famously right up until he was killed in the attack on the presidential palace. Our host Álvaro introduced us jokily to the leader of the left, saying: "This man has already made attempts to win the presidency and wants to have another go. But he'll never get there." Allende equally jokily chimed in: "Young man, do you know what's going to be on my tombstone?"

"No, doctor," I replied politely. "What is going to be on your tombstone?"

Amid renewed laughter Chile's future head of state replied using his full name: "Here lies Salvador Allende Gossens, future president of Chile."

On 21 September 1970, Allende had been declared victor of clean elections, but before he took over the presidency, after a fruitless effort by Chilean conservatives and their US allies to have the victory declared unconstitutional, Edward Korry, the US ambassador in Santiago, reported to Henry Kissinger, the foreign strategist of President Richard Nixon: "Once Allende comes to power we shall do all within our power to condemn Chile and the Chileans to utmost deprivation and poverty."

A few days earlier Richard Helms, director of the CIA, had scribbled notes on a meeting in Washington with Nixon, Kissinger and John Mitchell, the US attorney general, where the president demanded a coup. They read: "One in 10 chance perhaps, but save Chile! /worth spending /not concerned risks involved /no involvement of embassy /$10,000,000 available, more if necessary/ best men we have/ game plan/ make the economy scream /48 hours for plan of action."

After Allende's enemies finally claimed their victory against him on 11 September, Chileans protected themselves as best they could while Pinochet and his cohorts, well favoured now by Washington, turned to making themselves fortunes from the privatisation of public services and, quietly, from the trade in cocaine from Bolivia which the US never seemed to want to criticise or attack.

So confident was Pinochet in his protectors in "the free world" that on 17 September 1976 he ordered the killing of Orlando Letelier, Allende's former defence minister, with a bomb planted in his car in Sheridan Circle in the diplomatic heart of Washington itself. Such an atrocity, had it been committed by any Arab or Iranian, or indeed a Muslim of any persuasion, would have brought down instant punishment, or even war. But Pinochet was in no danger. After all, he had been Nixon's man all along.

Hugh O'Shaughnessy is the author of Pinochet, The Politics of Torture, published by Latin America Bureau and New York University Press