Rouhani is still seen as the frontrunner, but he faces a tougher than expected challenge from Raisi, who has rallied religious traditionalists and working-class voters disillusioned with the stagnant economy. This is the issue driving the campaign on all sides as the Islamic republic struggles with a 12.5-per cent unemployment rate and minimal growth outside the oil sector.
Rouhani won praise for taming inflation and easing sanctions through a nuclear deal with world powers, but his promises of massive foreign investment have not materialised, and Raisi has criticised his lack of support for the poor. "Rouhani stemmed the decline, but he over-did the austerity. Inflation was already falling. He failed to jumpstart the economy by spending more on development projects," said Djavad Salehi-Isfahani, an economics professor at Virginia Tech in the US who blogs about the Iranian economy.
Iran's missing reformists are the real heroes at Rouhani rally
Raisi has pushed his charitable credentials as head of the powerful Imam Reza foundation and vowed to create jobs, though with a notable lack of detail on how. The president says patience is needed for his plans to bear fruit, although it may be too late to win over struggling families.
For Clement Therme of the International Institute for Strategic Studies, the turnout will be the biggest issue in the election. "The regime needs participation. What matters most is the turnout, not the result," he said. "It's a difficult balance: if they control too much, people won't bother voting. But they can also use this part of the system to express their dissatisfaction."
With many disillusioned by the lack of improvements after past elections, this is a particular fear for the Islamic regime this year, and supreme leader Ayatollah Ali Khamenei has called for a massive turnout. Because it had the tacit approval of the supreme leader, Raisi supports the 2015 deal with world powers which saw curbs to Iran's nuclear programme in return for an easing of sanctions.
"The nuclear issue is not decided by the president and the future of the deal will depend on the Trump administration which is trying to change Iran's behaviour with the threat of force," said Thermes.
But Raisi has attacked the Rouhani government for his 'weak' stance during negotiations and for having failed to cash in on the deal. "We should not show any weakness in the face of the enemy," he said in a televised debate, raising the possibility that he could deepen already worsening tensions with Washington.
Rouhani has put civil liberties front and centre, knowing that this was key to his 2013 victory. He says his conservative opponents represent "violence and extremism" and that their era is over, but has struggled in the past four years to make headway against Iran's conservative-dominated judiciary and security services.
Rouhani in, Ahmadinejad out as Iran Guardians pick election candidates
Raisi has tried to present a relatively liberal image, emphasising that his wife is an independent and highly educated professional. But his gender-segregated rallies are in stark contrast to the mixed, youthful and middle class crowds turning out for Rouhani, who has been endorsed by leading reformists and celebrities such as Oscar-winning director Asghar Farhadi.
The government says it needs US$50 billion a year in foreign capital to get the economy moving, but investors and global banks remain nervous about remaining US sanctions and Iran's shady financial system.
Meanwhile, Iran's supreme leader has called for a self-sufficient "resistance economy", a point emphasised by Raisi. But in a country heavily dependent on oil exports, total independence is not realistic.
"No one is taking the 'resistance economy' idea to the extreme of Venezuela-style efforts to control prices and markets. Everyone sees some room for trade," said Salehi-Isfahani.
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