Iranians are waiting for the results from Friday’s presidential election, likely to be later than expected after voting was extended for five hours.
Officials pushed back voting deadlines four times, with long queues outside polling stations well into the evening.
The election will decide a successor to outgoing leader Mahmoud Ahmadinejad.
His eight years in power have been characterised by economic turmoil and Western sanctions against Iran over its controversial nuclear programme.
Although all six candidates are seen as conservatives, one of them – cleric Hassan Rouhani – has been reaching out to reformists in recent days.
Mr Rouhani has spoken publicly about the need to re-engage with the West and has promised to free political prisoners and reform the media.
The surge of support for him came after Mohammad Reza Aref, the only reformist candidate in the race, announced on Tuesday that he was withdrawing on the advice of pro-reform ex-President Mohammad Khatami.
Mr Rouhani now has the endorsement of two ex-presidents – Mr Khatami and Akbar Hashemi Rafsanjani – who was disqualified from the race by the powerful Guardian Council.
However, Mr Rouhani faces a tough challenge from hardline candidates, including top nuclear negotiator Saeed Jalili and Tehran’s mayor Mohammad Baqer Qalibaf.
The remaining candidates are seen as conservatives close to Iran’s supreme leader, Ayatollah Khamenei.
Polls eventually closed at 23:00 local time (18:30 GMT) and counting started soon afterwards. Results are due in the next 24 hours.
About 50 million people were eligible to vote and analysts predicted a high turnout.
If no candidate secures 50.1% or more of the vote a second round will be held in a week’s time.
As polls closed, representatives of all six candidates issued a joint statement urging their supporters to remain calm until the official results are known.
“We ask people not to pay attention to rumours of victory parades being organised and to avoid gathering before the official results,” the statement said.
Earlier, Interior Minister Mostafa Mohammad Najjar told state TV that any presidential candidates unhappy with the results would have three days to lodge complaints to the vetting body, the Guardian Council.
Mahmoud Ahmadinejad cast his ballot in Tehran accompanied by Vice-President Mohammad Reza Rahimi and government spokesman Gholam Hoseyn Elham, Fars news agency reported.
Friday’s presidential election is the first since 2009, when protesters took to the streets alleging the results had been rigged in favour of Mr Ahmadinejad.
No foreign observers have monitored the poll and there have also been concerns that media coverage in the run-up was unfair.
Many reform newspapers have been shut down, access to the internet and foreign broadcasters restricted, and journalists detained.
On Thursday, the BBC accused the Iranian authorities of putting “unprecedented levels of intimidation” on BBC employees’ families.
It said Iran had warned the families of 15 BBC Persian Service staff that they must stop working for the BBC or their lives in London would be endangered.
Tehran has so far made no comment on the allegation.
The Iran Project is not responsible for the content of quoted articles.