In the historic centre of Ferrara, an imposing statue of Girolamo Savonarola confronts passersby. Savonarola, a local boy, was a 15th-century preacher of fire and brimstone, making his name denouncing secular vanity, pagan idols and the corruption of clerical elites. The monument hails him as “the scourge of corrupt and slavish times, full of vice and tyrants”.

Savonarola was hanged for his troubles in 1498, but his brooding, disruptive presence in modern Ferrara seemed apt this month as the city, in northern Italy, hosted a group of modern iconoclasts with their own mission to “clean up” the country.

On a bitterly cold evening, MPs and senators representing the Five Star Movement (M5S), launched by Beppe Grillo, the comedian-turned-political rabble rouser, implored a packed piazza to use a referendum on the constitution on Sunday 4 December to send the prime minister, Matteo Renzi, packing.

Renzi, the telegenic, youthful leader of the centre-left Democratic party (PD), has placed his authority behind proposals to limit the powers of the senate, Italy’s second chamber. His plan involves cutting the number of senators from 315 to 100, all of whom would be appointed – rather than elected, as at present – and restricting their power to influence legislation.

Since 1948 the Italian constitution has preserved a perfect balance of powers between the two houses of parliament, frequently leading to legislative gridlock in Rome. Renzi claims that slimming down the role of the senate will, along with other reforms to strengthen executive power, finally free governments to govern. Crucially, he has indicated he will step down if the vote goes against him.

In other eras, a dry and technical debate might have preoccupied a few constitutional cognoscenti. But these are not ordinary times in western democracies. In Ferrara’s Piazza Trento e Trieste, Alessandro Di Battista, a rising star of Grillo’s movement, issued a populist call to arms. Renzi’s referendum, he told the crowd, was just the latest gambit by a political class determined to insulate itself from the people it should serve.

“This unelected senate will be constituted by the arselickers of the various parties”, said Di Battista, “and by those who are in trouble with the courts and need parliamentary immunity. They’re sealing the system off so it can’t be changed in the future.”

Such a devious manoeuvre should, he said, come as no surprise: “There are two Italys: on the one side the very wealthy few who look after themselves, and on the other the masses who live every day with problems of transport and public health.” As his audience launched into a favourite Five Star chant, “A casa! A casa!” (“Send them home”), Di Battista referenced the political earthquake that was in everyone’s mind.

“The election of Donald Trump is the American people’s business,” he said. “But what that election does show is that so many citizens are simply not taking the establishment’s bait any more.”

Eventually it was time for the Five Star “I say No’’ tour and its participants to move on to the next event in nearby Bologna. As one helper turned to collect technical equipment from the stage, the slogan on the back of his blue Vote No sweatshirt became visible. For veterans of Brexit and observers of the election of president-elect Trump, it carried an eerily familiar ring: “Sovereignty belongs to the people.”

Matteo Renzi, the prime minister, is in danger of becoming yesterday’s man at 41. Photograph: Campanini/AGF/REX/Shutterstock

Italy’s referendum was not meant to pan out this way. The last polls permitted before the vote give the No campaign a five-point lead. Yet to paraphrase David Cameron’s famous jibe at Tony Blair, Renzi was the future once. Last April, when both the lower and upper houses of parliament comfortably approved the prime minister’s constitutional package, the votes were celebrated as a historic breakthrough. A pragmatic non-tribal figure, Renzi, 41, was seen as the young technocratic leader who was finally reforming baroque structures of governance and rendering them fit for purpose. The markets, the European commission and Confindustria, the Italian equivalent of the CBI, warmly applauded the idea of a streamlined parliament with a more powerful executive. But, fatefully, Renzi decided he also wanted the backing of the people and called a referendum to rubber-stamp the changes. His vow to stand down if the reforms were rejected was an indication of his confidence.

That already feels like a different era. The winds of change in western democracies have since whipped up into a storm and, as the Brexit vote and the election of Trump demonstrated, voters have stopped giving the answers their politicians expect.

At an August rally in the coastal town of Giulianova, Grillo declared with characteristic asperity: “Today saying no is the most beautiful and glorious form of politics … whoever doesn’t understand that can go screw themselves.”

The Five Star leader has since jubilantly drawn connections between American “Trumpismo” and the grassroots populism of his own movement, which stands at 30% in the polls, level pegging with Renzi’s party. “This is mad stuff,” Grillo wrote on his blog. “It’s an apocalypse for the big papers, the intellectuals, the journalists. This is a huge general ‘Fuck off’.”

On the hard right, Matteo Salvini, leader of the anti-migrant Lega Nord, is also surfing the wave, describing Trump’s triumph as a strike against globalisation: “It’s the revenge of the people, of courage, of pride, of the desire for work and security; and it’s one in the eye for the bankers, the speculators and the journalists.”

Salvini’s No referendum rallies have been “Trumpified”, accompanied now by supporters waving blue placards, emblazoned “Salvini Premier”, designed to imitate those familiar from American town hall meetings. At a recent rally of 30,000 in Florence, he even wore a Trump trademark baseball cap, sporting a No slogan.

Matteo Salvini during the protest against Renzi in Florence. Photograph: Anadolu Agency/Getty Images

As the air of insurgency becomes unmistakable, the technical debate over reforming a 70-year-old constitution is in danger of becoming a sideshow. Perhaps the most disturbing poll for Renzi found last week that only 40% of Italians say they will vote on the reform package; 56% consider their vote to be more a verdict on the prime minister, his government and, by implication, the state of the nation.

If that bigger picture still dominates come polling day, it is hard to see anything but defeat for a man once billed as Italy’s Blair. After 13 years of a flatlining economy, Italians are battered, bruised and looking for somebody to blame. Unemployment is running at 11%, but is close to 40% among the young, who made up the bulk of the 107,000 who left the country last year to seek work abroad. The aftermath of the financial crash is estimated to have wiped out about a quarter of Italian industry. The average family income is less now than it was in 2007.

Traditionally among the most enthusiastic proponents of European integration, ordinary Italians are furious at the EU’s failure to share the burden of the huge migration surge to their southern shores. Lectures from Brussels on the need to cut public spending and balance budgets, given the desperately straitened times, have added insult to injury. It is no coincidence that a current bookshop bestseller – 1960: The Best Year of Our Lives – is a nostalgic evocation of the Italian postwar economic miracle, when the country’s growth was judged to outstrip Germany’s.

As initially strong support for his constitutional reforms has plummeted, Renzi has tried to turn the tide. In an attempt to woo an increasingly Eurosceptic electorate, he has begun to talk tough to Brussels, temporarily abandoning austerity targets and threatening to veto the EU budget unless other member states show more solidarity over migration.

Resorting to what opponents describe as scare tactics, he has also drawn attention to a recent spike in the interest rates on government bonds. The markets have become decidedly uneasy at the prospect of Italy becoming the next country to deliver a seismic shock at the polls. “The yield will get bigger if uncertainty grows,” noted the prime minister. “That’s not a threat: it’s just a fact.”

A sharp rise in the cost of financing Italy’s colossal public debt could spell disaster. But just as the so-called fear factor failed to keep Britain in the EU, there are few signs that Renzi’s economic warnings are having the desired effect.

Paola Battistini, a shopworker from Ferrara who attended the Five Star rally, says: “We have already been screwed by the banks. The least of our problems is what the markets think about a No vote or a Renzi resignation. This country needs to start thinking again about focusing on the needs and lives of citizens, not the banks.”

Lega Nord leader Matteo Salvini with France’s Front National leader Marine Le Pen at the first meeting of the Europe of Nations and Freedom congress in Milan this year. Photograph: Giuseppe Cacace/AFP/Getty Images

Just when he needs his political friends and allies, Renzi does not seem to have many, at least in his own party. During his two years in office, the prime minister has made himself deeply unpopular among sections of the left through two reforms in particular. Intended to free up the country’s labour market, the liberalising Jobs Act made it easier for employers to hire and fire workers. The move incurred the wrath of the unions, but has so far failed to achieve any significant rise in permanent employment, especially for the young.

The educational reform package, the buona scuola, handed new powers over hiring and salaries to headteachers, and became deeply unpopular among teachers, another core section of PD support.

Such moves were always going to be a tough sell with more traditional party members. Combined with a perceived autocratic “presidential” style, they have lost Renzi a great deal of goodwill. One of the PD’s elder statesmen, former prime minister Massimo D’Alema, has already declared he will vote No, condemning the referendum as a distraction from Italy’s real problems.

In Bologna’s university quarter – scene of faculty occupations and violent clashes in 1977 – the walls of Via Zamboni are covered with posters advocating a No vote. The arts and humanities building has become a hub of “No Renzi” activity. Sara Agostinelli, an art graduate who is likely to vote yes to the constitutional reforms, says: “How PD supporters vote is going to be vital. What are they going to do? If Renzi doesn’t win, it will be big trouble down the line.”

Her friend, Silvia Mimmotti, who is training to be a psychologist, agrees and laments the prime minister’s lack of strategic nous. “Renzi made a big mistake to put himself and his future at the centre of this. It’s not about him – it’s about Italy. But he has made it about himself and so he’s uniting the factions against him.”

If the orthodox left has failed to unite behind the prime minister, the right is also in a state of ferment, as it plots eagerly for a post-Renzi era that could arrive before Christmas. Inspired by Trump, the anti-euro Lega Nord leader Salvini has distanced his party from the more liberal, pro-European Forza Italia, which still looks to Silvio Berlusconi, now 80, as its spiritual leader.

Salvini has long attempted to model the Lega on France’s Front National, led by Marine Le Pen, with an emphasis on border controls, protectionism and an “Italians first” philosophy. In the wake of events in the US, he has now repudiated the centre-right label altogether, telling journalists: “I don’t want to talk any more about the internal dynamics of what used to be the centre-right. I won’t be using that term any more. What we need now is a sovereignty project. Renzi will be in power for a few more weeks. Whoever wishes to govern with us needs to know that the euro must be destroyed. We have to take back control of our currency.”

The Lega Nord, as its name indicates, is a northern rather than a national power, with its main strongholds in the north-eastern Veneto region. As Italy’s economy stagnates and the country struggles to cope with the influx of more than 120,000 migrants and refugees this year, the Lega’s aggressive nationalism and calls for closed borders are finding a bigger audience. But it is the prospect of a Grillo-generated “fuck off” moment in 2017 or early 2018, if Renzi loses his referendum, that is the stuff of nightmares in Rome and Brussels.

If the prime minister carries out his threat to resign, it will be up to the Italian president, Sergio Mattarella, to decide whether to appoint a caretaker government or call a general election. The former is more likely, but elections must in any case take place by early 2018 and Grillo will be perfectly placed to seize the moment.

“The Five Star Movement can take support from both the right and the left,” said Gianfranco Baldini, professor in European politics at the University of Bologna. “In the case of a No vote, they will be the big beneficiary.”

Formed only seven years ago, Five Star has become one of Europe’s biggest populist organisations and is now the main opposition in Italy. Still defining itself as a movement rather than a party, it attracts rightwing voters through a tough line on immigration and idealistic leftwingers through a devotion to direct democracy and the environment. Passionate denunciations of corruption in public life appeal across the political spectrum.

Apart from Grillo, 68, who cannot stand for parliament because of a conviction for manslaughter following a car accident in 1980, Five Star’s leaders are young, inexperienced and more used to protest than office. Since June, its newest star, Virginia Raggi, has endured a rocky few months after being elected mayor of Rome. But if the Five Star Movement becomes a government, the roller coaster ride, for Italy and for Europe, will have only just begun.

Virginia Raggi, Five Star’s mayor in Rome. Photograph: Dadi/AGF/REX/Shutterstock

Like Salvini, Grillo has called for a vote on leaving the euro – an “Italeave” referendum – in order that “the people can decide on monetary sovereignty”. Should that ever come to pass, one of the founder members of the EU would become the epicentre of a eurozone crisis that they can scarcely afford. A banking meltdown would become a genuine possibility; concern has been mounting throughout the year over the fragile finances of major Italian banks and one-fifth of loans in the banking system are categorised as troubled.

Not surprisingly, given the stakes, centrist politicians of various stripes are closing ranks ahead of next Sunday’s moment of truth. Delivering a passionate call to arms last week, Pier Ferdinando Casini, a senior figure in the senate and former president of the chamber of deputies, said: “Today, moderates have only one choice: help Renzi in order to prevent Italy falling into the hands of Grillo and the populists.”

During the past few weeks, as the referendum campaign has neared its climax, Baldini has combined his academic work with travelling around the central region of Emilia-Romagna, delivering talks on the constitutional reforms.

Author of Great Britain after Brexit, he has been struck by the parallels between the Italian and British referendums. “Both campaigns have been polarised and divisive,” he said. “Both have seen very bleak scenarios depicted by either side in attempts to scare the electorate, for example with the idea that a yes vote will usher in a very authoritarian regime.”

In his presentations, Baldini, who will vote yes, tries to go to what he sees as the nub of the issue. “The present constitution was drawn up in 1948,” he says. “It was a different world: an Italy that had emerged from a civil war between fascists and communists and one with deep divisions. It needed very strong checks and balances, which is why the senate was made so powerful. It’s not the same situation now.”

Unfortunately for Baldini, it is proving difficult to make that argument stick, such is the suspicion towards anything coming out of Rome. “In a small town [in Emilia Romagna] called Bagnolo-in-Piano,” he recalls, “an elderly man came up to me and said, ‘I enjoyed the discussion but I just don’t trust anybody any more. I want to keep hold of my vote for the senate.’ I responded that it’s common for the second chambers in European democracies to be appointed, but he didn’t care about that. And he’s not alone. People don’t trust leaders any more.”

Baldini points out that it would be a mistake to think the grassroots revolt against elites, led principally by Grillo, is a complete novelty in Italy. He cites the rise of the anti-politics Common Man’s Front, which took a million votes in the election of 1946 (motto: “Get off My Case”). In the 1970s, Marco Panella’s Radical party was influential in marshalling opposition to the “partitocracy” dominated by the then Christian Democrats and in championing civil rights on issues such as divorce and abortion. More recently, with the memory of the tangentopoli corruption scandal still fresh, Berlusconi won power as an “outsider” pledging to clean up politics and run Italy like a business.

“There have been regular crises of legitimacy in Italian politics – and waves of populism,“ says Baldini. “It goes in cycles.”

Nevertheless, he agrees that the referendum carries a significance far beyond the updating, or not, of Italy’s constitution. “In a way the stakes are even higher in Italy than for Brexit. The prime minister has gambled everything and there is no one in the wings to take his place if he goes.”

Guglielmo Giannini. Photograph: Mondadori/Getty Images

Waves of Italian populism

Common Man’s Front

In the chaotic aftermath of the second world war, Roman writer Guglielmo Giannini founded the Fronte dell’Uomo Qualunque (Common Man’s Front). Claiming to represent the beleaguered ordinary Italian, battered by Nazi occupation and the civil war between fascists and communists that followed, it stood against the major parties in 1946 elections and won more than a million votes. Fiercely anti-communist and popular in the south, it campaigned against “professional” politicians and in favour of the monarchy. Though shortlived, it left a legacy in the word qualunquismo, signifying an anti-political attitude.

A woman with a sign supporting the right to abortion without gynaecological exams, Italy, 1970s. Photograph: Keystone-France/Gamma-Keystone via Getty Images

The Radical party

In an era when Italian politics was dominated by three parties – the Christian Democrats, the Communists and the Socialists – civil rights activist and journalist Marco Pannella found a niche with the creation of the liberal Partito Radicale, and was influential in the battle for divorce and abortion rights. Pannella was a crucial player in one of the most significant moments in postwar Italian democracy, when a referendum on divorce was held in 1974. Voters were asked whether they backed the repeal of a law passed three years earlier permitting divorce for the first time in Catholic Italy. Alongside the growing feminist movement, Pannella passionately campaigned against the proposal, which was eventually rejected.

Silvio Berlusconi. Photograph: Langevin Jacques/Sygma via Getty Images

Berlusconi’s ‘clean up’

As Italy reeled from a huge political corruption scandal in the early 1990s, media mogul Silvio Berlusconi declared that he intended to scendere in campo (get out there - literally “enter the pitch”) to clean up the political system. Only three months after he had founded the Forza Italia party, which he still leads, Berlusconi became prime minister. Although he lost the 1996 general election, he returned to power as leader of a rightwing coalition in 2001 and became the dominant political figure of the next 10 years, despite being plagued by court cases relating to his businesses.

Beppe Grillo with Rome’s mayor Virginia Raggi during a ‘No’ march. Photograph: Remo Casilli/Reuters

Grillo and Five Star

In 2007 popular comedian Beppe Grillo staged a day of rallies, called Vaffanculo (Fuck Off) Day, across Italy, calling for the reform of Italian politics, including fixed terms for members of parliament and an end to political immunity for MPs with criminal convictions. The response was enormous and the Five Star Movement (M5S) was born. Though not a formal party, the M5S is now Italy’s main opposition. As well as limited terms for MPs, Grillo has called for a referendum on the euro and a tough line on immigration.