It was a meal where only four of the 14 participants spoke and nobody ate. Seated in front of crystal glasses, the finest porcelain laid out before them, the German chancellor, Angela Merkel, and her French counterpart, Nicolas Sarkozy, glared at the two men on the opposite side of the table. For both leaders, entrapped in Europe's escalating debt crisis, the emergency dinner – conducted on the sidelines of the G20 summit in Cannes in November 2011 – had suddenly become a defining moment that could make or break the eurozone, the EU's most ambitious project.

Greece had never come closer to euro exit, and united Europe had never come closer to collapse. "In all my years I have never witnessed behaviour so undiplomatic," recalled Evangelos Venizelos, Greece's deputy prime minister who along with the then PM, George Papandreou, was the focus of Merkel's frosty glare. "The climate was extremely heavy, absolutely tragic," he conceded in an exclusive interview. "And very, very aggressive."

As EU states head to the polls – amid concerns that political instability might yet open a new chapter in the eurozone crisis – revelations about just how close Greece came to being forced out of the euro have finally begun to emerge.

The disclosures have been grist to the mill of an anti-austerity opposition determined to prove that Athens had almost no say in the running of its affairs.

Nicolas Sarkozy and Angela Merkel sit opposite George Papandreou at the emergency dinner in November 2011. Venizelos described the atmosphere in the room as ‘very, very aggressive’. Photograph: Philippe Wojazer/AFP/Getty Images

The dramatic events in Cannes unfolded after Papandreou's bombshell decision to hold a referendum over the terms of a hard-won but highly controversial rescue programme to prop up the debt-ridden Greek economy.

The proposal, announced before stunned MPs of his socialist Pasok party after months of tortuous negotiations with the country's troika of creditors at the EU, ECB and IMF, sent shockwaves through Europe. Many feared the vote would plunge the continent into complete chaos at a time when debt-choked Italy looked as if it was going the same way as Greece.

In Berlin and Paris – where officials had just agreed to a bailout for Greece which included the biggest debt restructuring in world history – Merkel and Sarkozy were incensed. Their patience had run its course.

They summoned Papandreou to Cannes, determined to make the point – even if it meant using brute force to confront a democratically elected leader facing a population already seething over the price of such aid.

"Sarkozy was extremely irritated," said Venizelos, who was called to the meeting in his then capacity as finance minister. "Nobody could speak because he was talking continuously. Merkel was calmer but her message was clear: either you cancel the referendum or you hold one, immediately, that asks: 'yes or no to the euro'. And after that we'll see if we'll go ahead with the [next] instalment [of aid], the [rescue] programme, the haircut."

With the ultimatum came an intolerable dilemma. "Imagine the reaction of the markets. In three days we would have collapsed. We would never have got to the referendum because there would have been a run on the banks," Venizelos insisted. The referendum was supposed to be about the austerity programme, he says: "Was it good or bad? Never about our presence in the euro."

Greeks protest against austerity in Athens on 28 October 2011, days before the prime minister’s surprise announcement of a referendum on the bailout. Photograph: Yiorgos Karahalis/Reuters

Fearing the worse, Merkel then suggested Venizelos stay on to study all possible exit scenarios with Luxembourg's premier, Jean-Claude Juncker – then chairman of the Eurogroup of eurozone finance ministers – together with his German and French counterparts, "because the result may well be 'no'."

Both Juncker, who is known to harbour an affection for Greece, and Venizelos refused to stay.

Until now, none of those in the room – with the exception of the former French finance minister, François Baroin, who has since written of "psychological warfare" being waged – have spoken publicly about the meeting.

Papandreou had hoped the referendum would forge some consensus in a country riven by discord over the painful medicine it was being forced to take but under threat of national bankruptcy he was forced to abandon the idea and became the first EU leader to be felled by the crisis. He was swiftly replaced by the technocrat banker Lucas Papademos.

In his crisis memoir, El Dilemma, Spain's former prime minister José Luis Rodríguez Zapatero describes Sarkozy as being so enraged at Papandreou and his referendum plan that he jumped up on the dining table shouting: "You are a fucking psycho" at the Greek leader.

But for most of those present – including the IMF managing director, Christine Lagarde, and the current European commission president, José Manuel Barroso – that night in Cannes is one they are still unwilling to discuss.

Last week, as passions in Athens mounted, Germany's finance ministry was forced to deny accusations that Wolfgang Schäuble had advocated a Greek euro exit after officials, in a series of Financial Times reports, were cited as saying he had been the staunchest supporter of Greece quitting the single currency.

But contingency plans had been put in place by the time the EU's elite flew in to Cannes. Documents leaked to the Guardian reveal that by March 2012, the European Central Bank had compiled a road map of emergency steps to be taken if the debt restructuring plan looked unlikely to succeed and triggered a bank run.

The disaster scenario included a deposit freeze – with bank withdrawals limited to €100 a week – and capital controls, unheard of at that time in any EU member state.

When he recounts the events in Cannes Venizelos, a large man not given to evident vulnerability, still turns pale. Papandreou had told his finance minister nothing about the plan for a referendum before announcing it.

"He didn't tell me because he knew I would have been against it," said the politician, hinting at the bitter rivalry between the two men.

Greek prime minister George Papandreou tells parliament on 3 November 2011 that was prepared to drop plans for a referendum on the terms of a bailout. Photograph: Louisa Gouliamaki/AFP/Getty Images

At first Venizelos supported the idea because, he says, he did not want to further split the country or governing party. But when an email from Papandreou made him realise that the PM hadn't told other EU leaders, the finance minister felt so ill he was admitted into hospital with stress-induced appendicitis. "It was one thing not to inform me, quite another not to tell Merkel or Sarkozy or anyone in the EU. When I got that email at 1.30am asking: 'What will happen if we lose?' I said to him: 'Are you well? You announce all these things and ask now? Hadn't you thought about any of this before?' I felt so ill reading that mail I had to admit myself into the clinic at 4am."

At 6.30am, as Venizelos was hooked up to a drip, his phone began to ring. First came a call from Schäuble, then the EU monetary affairs commissioner, Olli Rehn, and then Juncker. All wanted to know what was going on. There was no other way – he had to join Papandreou and fly to Cannes.

There, Venizelos says he put in a stellar performance "defending my prime minister". But when he saw the country's future was at stake he changed tack: "The flight back [to Athens] was the most dramatic I have ever taken."

Papandreou had dug in his heels and, emerging from the meeting, announced the referendum would go ahead. Meanwhile, unbeknown to the Greek leader, Merkel and Sarkozy had held a joint press conference declaring that Greece had one choice, and it was "in or out" of the entire euro project.

"As finance minister I had to say something. If the next day, Greeks woke up with their country's European future being so uncertain we'd have had absolute panic and a run on the banks," Venizelos said. "We would have inflicted great damage on the eurozone in addition to destroying ourselves."

As the prime minister's jet flew back to Athens with Papandreou slumped in his seat asleep, Venizelos worked on a statement that would ultimately be the beginning of the end of the referendum.

Within minutes of landing his eight-paragraph announcement was released. "Greece's position within the euro is a historic conquest that cannot be questioned," said the announcement. "This acquis by the Greek people cannot depend on a referendum."

It was 4.45am – barely three hours before the banks in Greece opened and nine hours after the start of the meal in Cannes. The eurozone's darkest hour was over.