The foiled plot in Marseille sparked fears that the closing days of the campaign could be a target for extremists ahead of Sunday's first round of voting in the country's most unpredictable election in decades.
Elite police and intelligence agents arrested the two Frenchmen -- 23-year-old Clement Baur and Mahiedine Merabet, 29 -- on Tuesday in the Mediterranean port city.
Paris prosecutors said the men are accused of participating in a terrorist conspiracy as well as weapons charges.
Weapons found as France arrests 2 plotting attack
After searching the suspects' shared Marseille apartment, authorities said they uncovered an Uzi sub-machine gun, pistols, three kilogrammes of TATP explosives and a homemade grenade as well as an Islamic State group flag.
Police had been searching for them since April 12 following the interception of a video in which they pledged allegiance to IS.
The men had used a number of aliases, switched mobile phones frequently and used pre-paid bank cards to evade police.
Two days after the arrests, 39-year-old Karim Cheurfi shot dead a policeman on Paris's Champs Elysees avenue before being killed by police gunfire.
A note praising the Islamic State group was found near his body.
COMMENTS
Comments are moderated and generally will be posted if they are on-topic and not abusive.
For more information, please see our Comments FAQ