Updated

French politics was shaken to its core Sunday as far-right populist Marine Le Pen and centrist Emmanuel Macron advanced to a runoff presidential election after the first round of voting.

As it became clear that Le Pen would be one of the top two vote-getters, her rivals on the left and right urged voters to block her path to power in the May 7 runoff, saying her virulently nationalist anti-EU and anti-immigration politics would spell disaster for France.

"Extremism can only bring unhappiness and division to France," defeated conservative candidate Francois Fillon said. "As such, there is no other choice than to vote against the extreme right."

With 97 percent of votes counted, the Interior Ministry said Macron had nearly 24 percent, giving him a slight cushion over Le Pen's 21 percent. Fillon, with just under 20 percent, was slightly ahead of the far-left's Jean-Luc Melenchon, who had 19 percent.

The selection of Le Pen and Macron marked the first time in the 59-year history of the French Fifth Republic that neither of the country's two main parties, the Socialists and the Republicans, made the second round of presidential balloting. Macron, a 39-year-old investment banker, made the runoff on the back of a grassroots campaign without the support of a major political party.

With Le Pen wanting France to leave the EU and Macron wanting even closer cooperation between the bloc's 28 nations, Sunday's outcome meant the May 7 runoff will have undertones of a referendum on France's EU membership.

The euro jumped 2 percent to more than $1.09 after the initial results were announced because Macron has vowed to reinforce France's commitments to the EU and euro -- and opinion polls give him a big lead heading into the second round.

While Le Pen faces the runoff as the underdog, it's already stunning that she brought her once-taboo party so close to the Elysee Palace. She hopes to win over far-left and other voters angry at the global elite and distrustful of the untested Macron.

Le Pen, in a chest-thumping speech to cheering supporters, declared that she embodies "the great alternative" for French voters. She portrayed her duel with Macron as a battle between "patriots" and "wild deregulation" -- warning of job losses overseas, mass migration straining resources at home and "the free circulation of terrorists."

"The time has come to free the French people," she said at her election day headquarters in the northern French town of Henin-Beaumont, adding that nothing short of "the survival of France" will be at stake in the presidential runoff.

Her supporters burst into a rendition of the French national anthem, chanted "We will win!" and waved French flags and blue flags with "Marine President" on them.

With a wink at his cheering, flag-waving supporters who yelled "We will win!" in his election day headquarters in Paris, Macron promised to be a president "who protects, who transforms and builds" if elected.

"You are the faces of French hope," he said. His wife, Brigitte, joined him on stage before his speech -- the only couple among the leading candidates to do so on Sunday night.

France is now steaming into unchartered territory, because whoever wins on May 7 cannot count on the backing of France's political mainstream parties. Even under a constitution that concentrates power in the president's hands, both Macron and Le Pen will need legislators in parliament to pass laws and implement much of their programs.

France's legislative election in June now takes on a vital importance, with huge questions about whether Le Pen and even the more moderate Macron will be able to rally sufficient lawmakers to their causes.

In Paris, protesters angry at Le Pen's advance -- some from anarchist and anti-fascist groups -- scuffled with police. Officers fired tear gas to disperse the rowdy crowd. Two people were injured and police detained three people as demonstrators burned cars, danced around bonfires and dodged riot police. At a peaceful protest by around 300 people at the Place de la Republique some sang "No Marine and no Macron!" and "Now burn your voting cards."

Macron supporters at his Paris election-day headquarters went wild as polling agency projections showed the ex-finance minister making the runoff, cheering, singing "La Marseillaise" anthem, waving French tricolor and European flags and shouting "Macron, president!"

Mathilde Jullien, 23, said she is convinced Macron will beat Le Pen.

"He represents France's future, a future within Europe," she said. "He will win because he is able to unite people from the right and the left against the threat of the National Front and he proposes real solutions for France's economy."

Fillon, the Republican candidate said he would vote for Macron on May 7 because Le Pen's program "would bankrupt France" and throw the EU into chaos. He also cited the history of "violence and intolerance" of Le Pen's far-right National Front party, founded by her father, Jean-Marie Le Pen, who was trounced in the presidential runoff in 2002.

In a defiant speech to supporters, Melenchon refused to cede defeat before the official count confirmed pollsters' projections and did not say how he would vote in the next round.

In a brief televised message, Socialist Prime Minister Bernard Cazeneuve urged voters to back Macron to defeat the National Front's "funereal project of regression for France and of division of the French."

Socialist presidential candidate Benoit Hamon, who was far behind in Sunday's results, quickly conceded defeat. Declaring "the left is not dead!" he also urged supporters to back Macron.

Voting took place amid heightened security in the first election under France's state of emergency, which has been in place since gun-and-bomb attacks in Paris in 2015. On Thursday, a gunman killed a police officer and wounded two others on Paris' iconic Champs-Elysees boulevard before he was fatally shot.

The Associated Press contributed to this report.