LONDON — By the standards of British elections, the weekend rally at the Mermaid Theatre here was stunning — as two former prime ministers, the Conservative John Major and Labour’s Tony Blair, told voters they didn’t need to back candidates from their parties in Thursday’s election.

The rebellious call to cross party lines by the two elder statesmen — who both oppose Britain leaving the European Union — comes as many feel the choice in the coming election is the worst in a generation.

Many voters confess unease with the erudite but untrustworthy Prime Minister Boris Johnson and his plan for a hard, swift Brexit, and also with Labour leader Jeremy Corbyn and his own hard-left plan to remake the British economy under a socialist banner.

As the two main parties have moved away from the center and toward what many consider the extremes, voters in the middle are wondering where to go. This is especially so for the half of the country that doesn’t like Brexit.

The former Conservative prime minister Major, appearing by video link, told rallygoers Friday night that leaving the E.U. was the “worst foreign policy decision in my lifetime.” Brexit would make Britain “poorer and weaker,” he said, and risked breaking up the United Kingdom, as Northern Ireland and Scotland wandered off over time.

If given the chance, Major said, he’d cast a ballot for ex-Conservatives such as David Gauke, who was kicked out of the party with 20 other “Tory Rebels” by Johnson in September over their resistance to his Brexit plans.

“None of them left the Conservative Party; the Conservative Party left them,” Major said. “Without such talent on its benches, parliament will be the poorer, which is why — if I were resident in any one of their constituencies — they would have my vote.”

Major was followed by Blair, who paid tribute to his former political rival. “Here are five words I thought I would never say: Thank God for John Major.”

Blair said he would personally vote Labour but urged others to back “the best candidates.”

“If you look, constituency by constituency, you will know the best candidates to back. Back them.”

This election, Blair told the crowded theater, was “beyond surreal, but the threat to our country all too real.”

Pollsters say a significant portion of the pro-leave vote is coalescing around Johnson’s Conservative Party, as the electorate largely rejects the entreaties of Nigel Farage’s upstart Brexit Party, which is polling at 3 percent.

But what happens to the anti-Brexit vote is the big question that will determine the shape of the next Parliament and direction for the country.

Britain remains hopelessly split, almost down the middle, over Brexit, polls show.

Johnson’s Conservatives, who promise to “get Brexit done” have maintained a steady 10-point lead over Labour. But if Labour and the third largest party, the Liberal Democrats, were a bloc, they would represent a near majority.

The Liberal Democrats say they would cancel Britain’s decision in June 2016 to leave the European Union. A fourth party that’s expected to do well in the election, the Scottish National Party, also opposes Brexit.

Voters looking for a moderate middle are further muddled by the country’s disquiet over the two top candidates.

Johnson is one of the most popular politicians in Britain — but deeply divisive. People either like him, or they really don’t.

Johnson is arguably lucky in his opponent: Corbyn is the most unpopular Labour leader since Michael Foot, who led his party to a catastrophic loss to Margaret Thatcher’s Conservatives in 1983.

Labour’s position on Brexit is harder to explain than the Conservatives’. Officially, the party is neither pro-Brexit nor anti-Brexit. It’s pledging to negotiate a softer Brexit deal with the European Union — and then to hold a second referendum to allow voters to accept the deal or remain in the E.U.

Nick Boles, a former Conservative minister and member of parliament who quit his party over Brexit, has written of the “appalling choice” of 2019, the first election in modern history “in which you wouldn’t trust either of the prime ministerial candidates to mind your children for an hour, let alone run the country.”

Boles called his former colleague Johnson a “compulsive liar” and Corbyn a “totalitarian.”

The Economist called the election “Britain’s nightmare before Christmas.” “British voters keep being called to the polls,” the editors fretted, “and each time the options before them are worse.”

The Economist branded Corbyn “a sympathizer with dictators in Iran and Venezuela,” and worried that Johnson’s Tories “have grown scarier.”

Marcus Roberts, director of international politics at the respected polling outfit YouGov, said one of the big unknowns in the vote Thursday is whether those who don’t like Corbyn will “put a clothespin on their nose” and vote for a party they otherwise wouldn’t. Will Brexiteers in the north and Midlands who ordinarily vote Labour go with the Conservatives? Will anti-Brexiteers who oppose Corbyn vote Labour anyway, in the hope of getting a second referendum?

Guy Dorrell, 46, said he’s certainly no fan of Corbyn but will be voting for the Labour Party regardless.

“I really can’t bear Jeremy Corbyn — eww,” he said, shaking his head at the Mermaid Theatre after hearing Blair and Major speak.

But he said he’s going to vote for his local Labour candidate in London’s Battersea neighborhood. He’s arranged a “vote swap” with a partner in a different constituency, where he thinks his preference for Liberal Democrats might make more of a difference.

The anti-Brexit electorate is being urged to consider this kind of “tactical voting,” in which a person would cast a vote for a candidate they wouldn’t normally support to stop another, less desirable challenger from winning.

There are now a dozen websites helping such voters game out the possibilities, with particular attention to the highly contested seats.

Britain is a parliamentary democracy, so citizens don’t vote for Johnson or Corbyn but for their local representative to the House of Commons. The candidate with the most votes — the “first past the post” — goes to Westminster. The leader of the party that wins the most seats generally gets first crack at forming a government and becoming prime minister.

Sally Anne Smith, 57, works for the National Health Service. “I’m not a Corbyn supporter by any stretch,” she said, “but the alternative is unthinkable.”

Voting tactically, she said, meant voting for the party “most likely to unseat Boris Johnson.”

This would help “save my country from something as dangerous and as divisive and as isolating as Brexit,” which was “more important than tribal loyalties.”

A newsmaking frontman for tactical voting is actor Hugh Grant, who has been knocking on doors in recent weeks to urge voters to tick the box with the best chance of denying Johnson a majority in Parliament.

Grant, who played the tongue-tied puppy dog of a prime minister in the 2003 Christmas romantic comedy “Love Actually,” has campaigned alongside Luciana Berger, a former Labour lawmaker who quit her party over its struggle with anti-Semitism and is now running as a Liberal Democrat, and Dominic Grieve, who was kicked out of the Conservative Party by Johnson for opposing his Brexit plans and is running as an independent.

“As a father of five children, I want to save the country from catastrophe,” Grant said.

The last year has seen a pair of rallies of a million people out on the streets in London to decry Brexit.

Philippa Allen, a 53-year-old mother and former teacher, attended both. “I feel very strongly that we weren’t given the proper information” before the 2016 Brexit vote, she said.

Her constituency in the London suburbs of Orpington is a Conservative stronghold. For the past nine years, it has been represented in Parliament by Jo Johnson, Boris Johnson’s younger brother. Jo Johnson, who opposes his brother’s hard Brexit, resigned dramatically in September, saying he felt an “unresolvable tension” between loyalty to his family and the national interest.

“I do sense that there is a change in the air,” Allen said. “A lot of people are quite disgusted. My husband would normally vote Conservative, but he’s disgusted with what’s going on. I would normally vote Labour, although local Lib Dems are incredibly good. I’ll see whatever the tactical vote websites say.”

Pollsters say it’s possible more people will cast a vote for a party that backs a second referendum than a party that backs Brexit. And yet the Conservatives could win a majority in Parliament because of the way those voters are distributed — a prospect that would keep Britain divided for years to come.