The Greek prime minister George Papandreou's loss of power is not surprising: the reaction of Greeks to the 27 October agreement with its new tranche of austerity measures and the further undermining of national independence was devastating for the government. The next day, a military parade was abandoned as protesters occupied the streets, and the president had to flee; parades elsewhere were similarly interrupted. The political elites, who felt unassailable for 30 years, now sense the popular anger and are unable to comprehend or contain it.

The call for a referendum was the irrational act of a regime that had lost touch with the people and was trying desperately to save its skin. Papandreou's gambit looked like a veiled threat to the eurozone authorities and was interpreted as such by leaders who have been strongly rebuffed in recent referendums by the French and the Dutch - where two of the core nations rejected the European constitution and ended aspirations for the creation of a European superstate based on neoliberal principles. "Referendum", a dirty word in the corridors of Brussels, evoked the fear elites feel when the people momentarily enter the political stage.

But Papandreou's plan was not a late recognition or a democratic redress of the repeated humiliations visited upon Greeks, or a reassertion of sovereignty against the IMF and Germany. On the contrary, it was the government's attempt to regain the initiative against its own people clamouring to see it exit the stage. The inability to predict the angry reaction of the Europeans turns it into a dispiriting swansong of a dispirited and utterly defeated government, a blackmail that backfired.

First, it was a threat to the Greek people, who with their protests over 18 months have turned Greece into an ungovernable country. Papandreou was telling them that unless they accepted the new catastrophic measures they would be condemned to leave the eurozone and suffer a further collapse of living standards. Second, it was addressed to backbench Pasok MPs, stirring in response to popular pressure and the disastrous opinion polls. They were asked to give a vote of confidence to Papandreou last Friday, under the James Callaghan principle that "turkeys do not vote for an early Christmas".

But the gamble did not succeed. The Socialist MPs gave their confidence in order to delay elections and save the party from total collapse on condition that Papandreou resign and a national unity government formed. The frantic negotiations that followed between Pasok and rightwing New Democracy finally brought together the political elites in a big austerity coalition. Elections, initially planned for 4 December, will be delayed now as the two parties, obedient to European diktat, prepare to face a people who have largely rejected their political machinations.

The eventual departure of Papandreou may be the best outcome of the Greeks' long struggle so far: hot on the heels of the Arab spring, a reminder that western governments too can fall if they abandon basic principles of democracy, social justice and independence.

But the European involvement in this endgame is problematic. The picture of Papandreou dragged in to be reprimanded by Angela Merkel, Nicolas Sarkozy and the Eurocrats does not augur well for the future of the union. The decision to hold a referendum, the question to be put to the people or the composition of the government is a national political decision as in theory, Greece remains independent. The bailout is a loan (which will be paid back fully; the "haircut" relates to privately held bonds only). A loan to a sovereign government does not give the lending governments the power to treat the country like a protectorate. But this is what has been happening, increasing popular anger. The dispatch of colonial-type administrators to run the country under the recent proposals has now been completed.

It is not only Papandreou: Europe's hubris is also exposed. The Greek people with their prolonged struggles and sacrifices will finally get rid of their government. The weakest link has fallen partly as a result of popular resistance. Now the dominoes will move west. The economic future of Greece will be difficult, but democracy has won. The elite's fear of "contagion" should not be just about the euro – they should also fear Greek resistance spreading across Europe.