After the Prophet PBUH set out from Makkah with his companion, Abu Bakr-May Allah be pleased with him-stayed 3 days in the Cave of Thaur finally reached Madinah after building the first masjid of Islam in Quba, Masjid-ul-Quba and prayed the first Friday prayer there.
The people of Madinah have been waiting for the Prophet-Peace be upon him- since quite a long now, they would go to the outskirts of the city and look for his whereabouts.
The day the Prophet-Peace be upon him-arrived was a day rejoiced by the people of Madinah, he was warmly welcomed by them and everyone wanted him-Peace be upon him-to stay in their house. This decision was left by him -Peace be upon him-to his she-camel, Qaswa, as to where she would sit will be the place he-Peace be upon him-would stay. Qaswa sat at the site of the now Masjid An-Nabwi , which was an empty spot at that time belonging to two orphans. The Prophet-Peace be upon him-purchased this piece of land from the orphans, in spite of their refusal to take any money from the Prophet-Peace be upon him- and the construction of Masjid An-Nabwi commenced. The Prophet-Peace be upon him-himself participated in the construction, which is an exceptional example of a true leader.
One of the most important issue that had to be addressed was the rehabilitation of the Mujahreen, the Muslims of Makkah that had left all their belongings in Makkah and nothing at the moment. The Prophet-Peace be upon him-brotherhood amongst the Muhajreen and the Ansar (people of Madinah). Each Muhajir was placed in a brotherly relation with an Ansar.
The Ansar divided everything they possessed into half and gave it their Muhajir brother, their house, business, everything. They helped with everything they could possibly help with.
The next step taken was setting up the Charter of Madinah, which defined the relationaship between the Muslims and the non-Muslims living in Madinah and how Madinah would be governed under Islamic Law.
There were three main Jewish tribes living in Madinah, namley Banu Quraizah, Banu Qainiqah and Banu Nadeer. The Prophet-Peace be upon him-clearly outlined an agreement with them which stated as followed:
- The Jews have religious freedom and no interference would be done by the Muslims in respect to that.
2. Both parties, the Muslims and Jews, would protect Madinah in case of an attack.
3. Both parties would remain under friendly terms.
4. If either one of the party gets attacked, the other would help and defend them.
5. Neither one of them would help the Quraiysh.
6. If either one of them made peace with an enemy, the other would do so except if its in the case of religious dispute.
Thus, an agreement was made on how Madinah would run under the leadership of the Prophet-Peace be upon him-where everyone gets to practice their religion and be it a Muslim or non-Muslim everyone is treated with equality, no discrimination, no religious interference.