The first of an expected 2 million Muslims on August 19 began celebrating the hajj in Saudi Arabia, one of the five pillars of the world's fastest-growing religion.
Every Muslim is required to complete the hajj at least once in their lifetime if they have the means to do so.
The faithful have been arriving in Mecca from around the world in recent weeks, many chanting, "Labayk Allahuma Labayk," or "Here I am, God, answering your call. Here I am."
Muslims believe the hajj retraces the footsteps of the Prophet Muhammad, as well as those of the prophets Ibrahim and Ismail — known as Abraham and Ishmael in the Bible.
After prayers in Mecca, the faithful will move to Mount Arafat on August 20, where the Prophet Muhammad delivered his final sermon.
The last ritual will involve pilgrims going to an area called Muzdalifa. There, they will begin picking up pebbles for a symbolic stoning of the devil and a casting away of sins that takes place for three days in the Mina Valley.
The final days of hajj coincide with the Eid al-Ahda, the multi-day festival also known as the Feast of Sacrifice. Eid al-Adha and Eid al-Fitr, which marks the end of the holy Muslim month of Ramadan, are the two most important festivals in the Islamic calendar.
Saudi Arabia annual spends billions of dollars on security and safety measures in the biggest logistical challenge the Gulf nation faces, particularly in Mina.
On September 24, 2015, a stampede and crush of pilgrims in Mina killed at least 2,426 people, according to a count by the Associated Press.
The official Saudi government death toll was 769 people killed and 934 injured. Saudi officials have never explained the discrepancy.
Following the 2015 stampede, the Saudi government has widened some roads to try to improve the safety of the hajj.
Saudi King Salman's official title is the "Custodian of the Two Holy Mosques," at Mecca and Medina.