Nicolas Sarkozy has launched an impassioned appeal to French voters “not to take the path of extremes” as far-right leader Marine Le Pen leads polls heading into the country’s presidential election.

Mr Sarkozy, who served as President from 2007 to 2012, ran to represent the centre-right Les Républicains party but was beaten into third place in the first round of primaries.

“I respect and understand voters’ wish to choose other political leaders than myself for the future,” he said following his defeat on Sunday.

Nicolas Sarkozy speaking after his defeat in the French conservative presidential primary in Paris, France, on 20 November (Reuters)

“However, I would ask them never to take the path of extremes. France deserves so much better than the worst possible choice.”

His remarks were widely taken as an attack on France’s far-right Front National, which has been rapidly gaining popularity under Ms Le Pen’s leadership.

The anti-immigration group, which hailed the “collapse” of Europe’s political order following Donald Trump’s victory, has sparked controversy over its positions on Islam and founder Jean-Marie Le Pen’s convictions for inciting racial hatred and statements on the Holocaust.

His daughter came third in the first round of France’s last presidential election in 2012, when Mr Sarkozy ran unsuccessfully against Francois Hollande.

She now hopes to do much better, with the latest poll by Ipsos giving Ms Le Pen head with 29 per cent of the vote when pitted against Mr Sarkozy and the left-wing Parti de Gauche’s Jean-Luc Mélenchon, among other potential candidates.

Les Républicains’ remaining runners are Alain Juppe and former Prime Minister Francois Fillon, who was backed by Mr Sarkozy as he hinted at a permanent withdrawal from politics.

France's far-right National Front (FN) leader Marine Le Pen poses in front of a poster for her 2017 French presidential election campaign (REUTERS/Charles Platiau)

“Good luck to France,” he said. “I wish the very best for my country, for you my dear fellow citizens, and for the one who will lead this country that I love so much.

“I was happy to have participated in this battle. Goodbye to all.“

Mr Fillon is in a commanding position for next Sunday's second round of a contest that is widely expected to decide France's next leader, with the winner tipped to beat Ms Le Pen in the decisive presidential run-off next May.

He and Mr Juppe have broadly similar programmes, underpinned by pledges to reinforce domestic security in a country still under a state of emergency following Isis terror attacks have that killed more than 230 people.

They also share a desire to reinforce European borders and reduce immigration, while tax cuts also loom large, seeking to prevent a shift in voters to the more right-wing Front National.