Iran will choose a new president on Friday in what is emerging as a two-horse race between moderate ex-premier Mir Hossein Mousavi and incumbent Mahmoud Ahmadinejad, whose turbulent four years in office have been marked by a nuclear standoff with the West and deep economic crisis.
The country is gearing up for a tense battle in Friday's election after a campaign of mudslinging and unusually feisty televised debates between the four candidates.
Running alongside Ahmadinejad and Mousavi are reformist ex-parliament speaker Mehdi Karroubi, the only cleric among the candidates, and the conservative former head of the elite Revolutionary Guards Corps, Mohsen Rezai.
But the race has become a straight fight between Ahmadinejad -- the hardline outspoken son of a blacksmith, and Mousavi -- the last man to hold the post of premier who steered the economy during Iran's war with Iraq in the 1980s.
The next Iranian president will take power at a defining moment for the Islamic republic's foreign policy with diplomatic overtures from American President Barack Obama offering a chance to turn the page.
For years Iran has derided the United States as the "Great Satan," while Obama's predecessor George W. Bush labeled Tehran part of an "axis of evil" and refused to rule out military action over Iran's nuclear program.
But now Tehran has an opportunity to mend three decades of broken relations with Washington and pursue a negotiated solution to the nuclear standoff with the West which has seen the U.N. Security Council impose three sets of sanctions.
The next president will not take the big decisions -- the Iranian political system gives the final say on strategic issues to supreme leader Ayatollah Ali Khamenei.
But whoever wins this month's election will play the key role in implementing the policy and handling what may be a turning point in Iran's relations with the outside world.
"The core of Iran's foreign policy after the election will revolve around how to respond to Obama's moves and managing the nuclear talks with global powers," political analyst Mashaallah Shamsolvaezin told AFP.
"Until now, it was easy for Iran to blast the United States, especially after what Bush did," Shamsolvaezin said.
"But under Obama things have changed. There is a belief among Iranian leaders that, if required, Obama has the ability to turn the world against Iran, which is why Iranian leaders have to resolve all the outstanding issues with Washington during Obama's term."
Soon after taking office in January, Obama said his administration was ready to extend a diplomatic hand to Iran if it "unclenches its fist."
Gestures to Iran
And on Thursday, Obama made a significant gesture to Iran, becoming the first sitting president to acknowledge American involvement in the 1953 coup which overthrew the government of Prime Minister Mohammad Mossadegh, a longstanding Iranian demand.
But U.S. officials have also made clear that if Tehran spurns the overtures, Washington will seek much tougher U.N. action over Iran's nuclear program, which Western governments suspect is cover for a drive for an atomic bomb, a charge Tehran vehemently denies.
The program was frozen under Khatami, but Ahmadinejad resumed it after taking office in 2005, calling the suspension "shameful."
Since then he has doggedly pursued the nuclear agenda, while Iran has regularly boasted of testing new missiles that could reach its foes in the region.
Kamran Daneshjoo, the head of Iran's election committee, said on Monday he expected "record-breaking turnout" among the 46.2 million eligible voters, half of whom were born after the 1979 Islamic revolution.
He predicted turnout would be high "despite the propaganda of the arrogant nations (Western powers) who are undermining the election."
Analysts are still hesitant to pick a winner, suggesting the vote may be a repeat of 2005 when a relatively unknown Ahmadinejad scored a stunning upset in a second-round runoff against heavyweight cleric Akbar Hashemi Rafsanjani.
A runoff will be held on June 19 if no single candidate emerges with 50 percent plus one vote in the first round.
If Ahmadinejad, 52, is defeated, it will be the first time a sitting president is ousted after a single four-year term.
Ahmadinejad's 2005 victory swept the conservatives back into the top echelon of Iranian politics after eight years under reformist cleric Mohammad Khatami who failed nevertheless to implement many of his reforms.
The four candidates in Friday's race were the only ones to survive a screening by the powerful Guardians Council out of a total of 475 Iranians who registered as prospective candidates, including 42 women.
Khatami and several other reformists have thrown their weight behind Mousavi and anti-Ahmadinejad groups are urging voters to turn out in large numbers to ensure his defeat.
"A 50 percent voter turnout is good for Ahmadinejad, but if around 35 million voters come to the ballot boxes, then it is trouble for him," Shamsolvaezin told AFP.
He said nearly 50 percent of the eligible voters are "silent voters" who are usually against the hardliners and if they vote in large numbers, it "could turn the game" against Ahmadinejad.
OPEC's second largest oil exporter earns 50 percent of its revenues from oil sales, making its economy heavily dependent on volatile crude prices.
Economists have charged that despite the windfall oil revenues in the first three years of his term, Ahmadinejad's expansionist policies are mainly responsible for Iran's chronic economy.