More than one million Muslim pilgrims have begun a symbolic devil-stoning ritual in Mina on the third day of the Hajj pilgrimage.
Pilgrims threw pebbles at a stone wall outside Mecca, shaved their heads and bought sacrificial animals.
Hajj centres around Mecca, Mina and Medina, all located in western Saudi Arabia.
Many arrived for the ritual on Wednesday after walking about 20km during the night, stopping for a few hours of sleep in the Muzdalifa area, where they collected at least 49 pebbles.
They were coming from Mount Arafat, east of Mecca, where the Hajj reached its spirtual climax on Tuesday.
The stone-throwing ritual has been the most dangerous stage in an event which has seen a series of tragic accidents in recent years.
More than 1.6 million people performed the Hajj this year.
Pilgrims had the choice of three walkways to approach the stone and concrete wall, a modernised version of what used to be a stone pillar.
The ritual represents defiance of the devil and commitment to resisting his temptations.
[b]Ahmadinejad's Visit [/b]
This year, Mahmoud Ahmadinejad is attending the Hajj at the invitation of Saudi Arabia's King Abdullah.
Ahmadinejad thus became the first Iranian leader to take part in the Hajj.
His pilgrimage to Islam's holiest sites is Ahmadinejad's third visit to the country since taking office.
He visited Mecca in December 2005 for an Organisation of the Islamic Conference (OIC) summit but outside of the Hajj season.
Rocky relations
Relations have been rocky between Shia majority Iran and Sunni majority Saudi Arabia, which also has a substantial Shia community in its oil-rich eastern province.
Relations reached an all-time low in July 1987 when 402 people were killed in clashes between Iranians and Saudi security forces during the Hajj.
However, Ahmadinejad's appearance is seen as a sign of warming relations between the two countries.
Shortly before the Hajj, Iran urged Saudi Arabia to crack down on religious extremism following reports of anti-Shia sermons and pamphlets in the kingdom.
Source: aljazeera