Canadians have begun voting in a general election, with surveys predicting that Prime Minister Justin Trudeau's Liberal Party could return with a weakened minority government or lose his grip on power entirely.
The Liberals and the Conservatives, led by Andrew Scheer, were set for a near dead heat with pundits calling it one Canada's closest elections.
Polls opened at 11am GMT in the province of Newfoundland in eastern Canada, the first of the country's six time zones - with some 27.4 million Canadians eligible to elect 338 members of parliament.
The first results are expected to start at 11pm GMT, a few hours before voting wraps up in westernmost British Columbia at 2am GMT tomorrow.
After 40 days of campaigning, neither of the parties - Liberal or Conservative - that have led Canada since Confederation in 1867 is expected to secure an absolute majority of seats in parliament.
At final campaign stops in westernmost British Columbia yesterday, Mr Trudeau made an emotional appeal to voters to enable him to build on the achievements of his first term.
He warned against Mr Scheer's pledged rollback of environmental protections including a federal carbon tax that discourages the use of large amounts of fossil fuels.
"We need a strong, progressive government that will unite Canadians and fight climate change - not a progressive opposition," Mr Trudeau told a rally in a suburb of Vancouver after whistle-stops in Ontario, Manitoba and Alberta.
"We need to unite as citizens. We need to unite as a planet."
Mr Trudeau's star has dimmed since winning in a 2015 landslide that echoed the wave of support that carried in his bullish, flamboyant late father Pierre in 1968.
His image has been tainted by ethics lapses in the handling of the bribery prosecution of an engineering giant, while his campaign was rocked by the emergence of old photographs of him in blackface make-up.
Surging social democrats and resuscitated Quebec separatists have also chipped away at Liberal support.
Mr Trudeau, accompanied by his wife and children, voted in the morning in Montreal while Mr Scheer was to cast a ballot in Regina, Saskatchewan.
If Mr Trudeau hangs on, it will be because Mr Scheer has struggled to win over Canadians with his bland minivan-driving dad persona and a throwback to the thrifty policies of past Tory administrations.
Canadians "cannot afford" a Liberal government propped up by the third-place New Democratic Party (NDP), Mr Scheer said at the end of a marathon last push from the Atlantic to Pacific oceans.
"We can only imagine what the NDP's price would be to keep Justin Trudeau in power," he said.
"Whatever it is, we know Trudeau would pay any price to stay in power and he'd use your money to do it."
The campaign has been described as one of the nastiest ever, with attack ads including false accusations that Liberals would legalise hard drugs and that the Tories would allow the proliferation of assault weapons.
At one rally, Mr Trudeau was forced to wear a bulletproof vest.
Along the bruising way, Mr Trudeau and Mr Scheer traded barbs.
Mr Trudeau evoked the bogeymen of past and current Tory parties fostering "politics of fear and division" and Mr Scheer called the prime minister a "compulsive liar," "a phony and a fraud".
Mr Trudeau defended his record: a strong economy and low unemployment, legal cannabis, the resettlement of 60,000 Syrian refugees, doctor-assisted deaths, a public inquiry into missing and murdered indigenous women and free trade deals with Europe, Pacific nations and North American neighbours.
Former US president Barack Obama endorsed Mr Trudeau, calling him an "effective leader who takes on big issues like climate change."
"The world needs his progressive leadership now," Mr Obama said in a tweet.
I was proud to work with Justin Trudeau as President. He's a hard-working, effective leader who takes on big issues like climate change. The world needs his progressive leadership now, and I hope our neighbors to the north support him for another term.— Barack Obama (@BarackObama) October 16, 2019
The Conservatives, meanwhile, have stood alone among all of the parties in pledging austerity measures to return to a balanced budget within five years.
Mr Scheer was shaken late in the campaign over revelations of his US dual citizenship and allegations that his party hired a communications firm to "destroy" the upstart People's Party, led by former Conservative foreign minister Maxime Bernier.
The party has situated itself to the right of the Conservatives and could draw votes away.
On the left, the Bloc has come back from a ruinous 2015 election result, tapping into lingering Quebec nationalism to challenge the Liberals' dominance in the province.
The Bloc and NDP have said they would not prop up the Tories if they secure a minority.
So who will govern may still be unclear for weeks after the polls close during alliance negotiations that could keep Trudeau in office even if his party loses.