Makkah was the last city whose conquest led to the absolute domination of Islam over the Arabian Peninsula . It has the Haram (Sacred premises) of Allah and the site of Ka'bah. This city fell in the hands of the army of Islam in the 8th year of Hijrah. Shortly afterwards, the city of Ta'if was also conquered.
In the 10th year of Hijrah, the Holy Prophet (SA) set out for Makkah to perform the Hijjatul Wada' (last Hajj). After performing the Hajj manasik (rituals) and giving necessary instructions to the people, the Holy Prophet (SA) headed for Madinah. In the course of his journey, he ordered to stop the caravan at a place called "Ghadir (Pond) Khumm." Among one hundred and twenty thousand Hujjaj (pilgrims) who had gathered for Hajj from all parts of the Arabian Peninsula , the Holy Prophet (SA) took 'Ali's hand in his own, lifted him up, and announced his Imamah (succession of Prophet Muhammad [SA]).
By this action, the matter of succession, which controls the affairs of the Muslims, guards the Book and ahadih, and protects the divine instructions and laws, was resolved. Thus the order given by Allah in the following Ayah was executed: "O Messenger! deliver what has been revealed to you from your Lord; and if you do it not, then you have not delivered His message;...(5:67)"
Shortly, after returning to Madinah, the Holy Prophet (SA) passed away.
source : http://www.abna.ir/