The hajj, one of the world's largest annual religious gatherings, is one of the five pillars of Islam
More than two million Muslims begin the annual hajj on Friday as the Saudi hosts seek to deter politicisation of the pilgrimage against a backdrop of simmering Gulf tensions.
The hajj, one of the world's largest annual religious gatherings, is one of the five pillars of Islam and must be undertaken by all Muslims with the means at least once in their lives.
It consists of a series of religious rites which are completed over five days in Islam's holiest city and its surroundings in western Saudi Arabia.
"All of the arms of state have been deployed (and) we are proud to serve as 'God's hosts'," said security forces spokesman Bassam Attia.
In total, some 2.5 million faithful, the majority from abroad, will undertake the pilgrimage this year, according to Saudi media.
"More than 1.8 million visas were delivered online without the need for middlemen. It's a success," said hajj ministry official Hatim bin Hassan Qadi.
"We feel cleansed by achieving this pillar of Islam and meeting people from across the world. It's marvellous," said Mohamed Jaafar, a 40-year-old Egyptian pilgrim.
"It's an indescribable feeling. You have to live it to understand it," said an Algerian in his fifties completing the pilgrimage for the first time.
"It's a golden opportunity and moment," said his female companion.
Built in a desert valley, Mecca is home to the Kaaba, a cube structure that is the focal point of Islam and draped in a gold-embroidered black cloth.
Muslims around the world pray towards the Kaaba, which is located in the Grand Mosque, and pilgrims walk around it seven times.
Worshippers participated in weekly prayers late on Friday morning.
"The whole world is here... being here in Mecca is the best feeling," said Mohamed Barry, a pilgrim from Britain.
During the pilgrimage, separate streams of men and women, grouped by nationality, will travel to Mina on foot or in buses provided by the authorities.
A district of Mecca, Mina sits in a narrow valley surrounded by rocky mountains and is transformed each year into a vast encampment for pilgrims.
A total of "350,000 air-conditioned tents have been pitched," a Saudi official said.
Worshippers will climb Mount Arafat, also known as the "Mount of Mercy", for hours of prayers and Koran recitals.
After descending, they will gather pebbles and perform the symbolic "stoning of the devil".
That marks the beginning of Eid al-Adha, the festival of sacrifice, marked on Sunday.
Pilgrims then return to the Grand Mosque to perform a final "tawaf" or walk around the Kaaba.
This year's hajj takes place to a backdrop of Gulf tensions following a series of attacks on tankers, the downing of drones and the seizure of ships.
Riyadh blames regional foe Tehran for the attacks on commercial shipping, accusations Iran vehemently denies.
Despite the absence of diplomatic ties between the two countries, some 88,550 Iranian pilgrims are due to take part in the hajj this year according to Iran's Tasnim news agency.
As in previous years, Saudi authorities have been at pains to stress that the hajj is a religious event and have sought to prevent its politicisation.
Riyadh insisted its two-year embargo on Doha -- which includes restrictions on Qataris travelling to the kingdom -- would not affect the pilgrimage.
But hajj official Hassan Qadi acknowledged "very few Qataris have come to Mecca for the pilgrimage".
Saudi Arabia's hajj ministry accused Qatar of "politicising the hajj and creating obstacles for Qatari pilgrims," the official Saudi Press Agency reported.
The scale of the pilgrimage presents vast security and logistical challenges, with tens of thousands of safety officers deployed.
Riyadh faced strong criticism in 2015 when some 2,300 worshippers were killed in the worst stampede in the gathering's history.