A Great Sacrifice
That night, Imam `Al¢ (a.s) replaced the Holy Prophet in bed. The armed forces of Quraysh besieged the Holy Prophet's house. In the morning, they drew their swords and entered the house in a rampage, but they found Imam `Al¢, not the Holy Prophet, in the bed. Realizing that they had been betrayed, they charged against `Al¢. Drawing his sword, he stood opposite against and refused to tell them where the Holy Prophet was.
Anybody who would replace the Holy Prophet in bed had little chance to survive. However, `Al¢, who had replaced the Holy Prophet in bed many times before that event, such as he had done when they were besieged in Ab£-±¡lib Col, in purpose of securing his safety, sacrificed his life to protect the Holy Prophet's. Referring to this bravery and sacrifice of Imam `Al¢, Almighty God says:
And among men is he who sells himself to seek the pleasure of Allah; and Allah is Affectionate to the servants. (2:207)
Exegetes of the Holy Qur'¡n agree that this verse was revealed on account of the sacrifice and bravery of `Al¢ at that night, which is called laylat al-mab¢t.
Referring to the conspiracy of Quraysh during that dangerous night, Imam `Al¢, in one of his sermons, describes his mental condition as follows:
The Prophet ordered me to spend that night on his bed (while he would be leaving for Medina) and use my life as a shield for the protection of his life. I accepted it on the spot. I would be glad to die for him. The Prophet left me and I slept on his bed. The Quraysh armed forces entered, hoping to murder him. When they charged at the room where I was staying, I stood up, drew my sword and protected myself. This is the issue of which God is aware and people know.”
The Prophet's Arrival at Qub¡
Prior to his departure from Mecca, the Holy Prophet asked Imam `Al¢ to give back people's deposits and prepare for the departure of his daughter, F¡§imah, and some other men and women from Ban£-H¡shim, who had not yet departed Mecca.
On the fourth of Rab¢` al-Awwal (the 14th year after prophethood), the Holy Prophet left Thawr Cave for Yathrib. Eight days after that, he arrived at the district of Qub¡, on the outskirts of Yathrib, where the tribe Ban£-`Amr ibn `Awf lived. He waited there for a few days, waiting for `Al¢'s arrival. During this time, he established a mosque there.
After the Holy Prophet's migration, `Al¢ (a.s) stayed for three days in Mecca and carried out his obligations and tasks. He then accompanied his mother F¡§imah bint Asad and F¡§imah daughter of the Holy Prophet and F¡§imah daughter of al-Zubayr ibn `Abd al-Mu§§alib and two others to Qub¡ where they joined the Holy Prophet.
Arrival at Yathrib
Upon the arrival of `Al¢ at Qub¡, the Holy Prophet headed for Yathrib with a group of Ban£’l-Najj¡r (his maternal uncles). On their way, he performed the first Friday Prayer at the resort of Ban£-S¡lim ibn `Awf. Upon their arrival at Yathrib, they were passionately welcomed by people. The heads and chiefs of the tribes took the rein of the Holy Prophet's palfrey and begged him to stay with them. He answered, “Let the camel proceed; it has a mission to perform; wherever it sleeps, I will stay.”
By this decision, the Holy Prophet most probably wanted not to give the honor of being the host to any special group so that he could avoid future conflicts. His discretion was similar to one concerning the place of the installation of the Black Stone of the Kaaba.
Finally, the camel came to rest in the district of Ban£’l-Najj¡r, on a piece of land belonging to the two orphans, close to the house of Ab£-Ayy£b An¥¡r¢ (Kh¡lid ibn Zayd Khazraj¢). All people were now crowding around the Holy Prophet; they asked him to give them the honor to be their guest. Ab£-Ayy£b took the Holy Prophet's baggage to his own home and the Holy Prophet followed. He stayed there until the Masjid al-Nab¢ (The Prophet’s Mosque) was established and there was a room built next to it for the Holy Prophet to live in.
 The event of D¡r al-Nidwah (House of Consultation) and Laylat al-Mab¢t (the Night of Staying) have been recorded in the following reference books, yet with little difference: T¡r¢kh al-±abar¢ 2:242-245; al-S¢rah al-Nabawiyyah 2:124-128; Al-±abaq¡t al-Kubr¡ 1:227-228; Dal¡'il al-Nubuwwah 2:147; Ans¡b al-Ashr¡f 1:259- 260; al-K¡mil f¢’l-T¡r¢kh 2:101-103; T¡r¢kh al-Ya`q£b¢ 2:32; I`l¡m al-War¡, pp. 61; Shaykh al-±£s¢’s al-Am¡l¢, pp. 245- 247 and 463- 471; Ibn Shahr¡sh£b’s Man¡qib 1:182- 183; al-Khaw¡rzmi’s Man¡qib, p73; al-Kar¡jak¢’s Kanz al-Faw¡'id 2:55; Ibn Kath¢r’s al-Bid¡yah wa’l-Nih¡yah 3:175-180; Ibn Hush¡m’s al-S¢rah al-Nabawiyyah 2:189-206; al-Kha§¢b al-Baghd¡d¢’s T¡r¢kh Baghd¡d 13:191-192; Bi¦¡r al-Anw¡r 19:47- 65.
 Al-Fatt¡l al-Nays¡b£r¢, Raw¤at al-W¡`i¨¢n, pp. 117; Ibn al-Ath¢r, Usd al-Gh¡bah 4:25; Shablanj¢, N£r al-Ab¥¡r, pp. 86; ±abars¢, Majma` al-Bay¡n 1:301; Ibn Ab¢’l-°ad¢d, Shar¦ Nahj al-Bal¡ghah 13:262; Sib§ ibn al-Jawz¢, Tadhkirat al-Khaw¡¥¥, pp. 35; Ab£-Bakr °amaw¢, Thamarat al-Awr¡q, pp. 20; `All¡mah Am¢n¢, al-Ghad¢r 2:48. `All¡mah Am¢n¢ has reported this event from different reference books, such as, al-Mu¨affar’s Dal¡'il al-¯idq 2:80. Al-Mu¨affar, al-Tha`lab¢, al-Qanad£z¢, al-°¡kim al-Nays¡b£r¢, A¦mad ibn °anbal, Ab£’l-Sa`¡d¡t, al-Ghazz¡l¢, al-Fakhr al-R¡z¢, and al-Dhahb¢—all these Sunni master scholars report that this verse was revealed about Imam `Al¢’s self-sacrifice at that night.
 ¯ad£q, al-Khi¥¡l 2:367; Muf¢d, al-Ikhti¥¡¥, pp. 165.
 Ibn Hush¡m, al-S¢rah al-Nabawiyyah 2:129; ±abar¢, op cit, 2:247; al-Bul¡dhar¢, Ans¡b al-Ashr¡f 1:261; Ibn Shahr¡sh£b, al-Man¡qib 1:183.
 Shaykh al-±£s¢, al-Am¡l¢, pp. 468; Muf¢d, al-Ikhti¥¡¥, pp. 147; al-Suy£§¢, T¡r¢kh al-Khulaf¡', pp. 166.
 Mu¦ammad Ibn Sa`d, Al-±abaq¡t al-Kubr¡ 1:292; al-Majlis¢, Bi¦¡r al-Anw¡r 19:87.
 Ibn Hush¡m, op cit, pp. 137; ±abar¢, op cit, pp. 248; ±abars¢, I`l¡m al-War¡, pp. 64; al-Bul¡dhar¢, op cit, pp. 263; al-Bayhaq¢, Dal¡'il al-Nubuwwah 2:172
 Ibn Shahr¡sh£b, op cit, op cit, 1:185; al-Bayhaq¢, op cit, pp. 166, 172; ±abar¢, op cit, 2:249.
 Ibn Hush¡m, op cit, pp. 138; ±abar¢, op cit, pp. 249.
 Ibn Shahr¡sh£b, op cit, pp. 183; see I`l¡m al-War¡, pp. 66; T¡r¢kh al-Ya`q£b¢ 2:34
 op cit.