After the crushing defeat at Badr, the Quraysh burned with desire for revenge. Abu Sufyan ibn Harb had sworn not to wash his hair until he had fought the Muslims. In Shawwal of the third year after the Hijrah (March 625), he assembled a powerful army of 3,000 fighters, including 700 men in armour and 200 horsemen, with 3,000 camels as pack animals. Women of the Quraysh, led by Hind bint 'Utba (the wife of Abu Sufyan), accompanied the army to spur the men on and prevent them from fleeing as they had at Badr.
When the news reached Madinah, the Prophet ﷺ called the Companions together for consultation. He himself preferred a defence from within Madinah: the city had sturdy stone houses and narrow streets that offered a defensive advantage. 'Abdullah ibn Ubayy ibn Salul, the chief of the hypocrites, supported this plan.
However, younger Companions who had missed Badr and ardently longed for martyrdom urged an open confrontation outside the city. Hamza ﵁ exclaimed: “By the One Who has sent down the Qur’an, I will not eat today until I have fought them with my sword outside Madinah!” The Prophet ﷺ, following the wish of the majority, donned his armour and marched northward with 1,000 men.
On the way, at the lava rocks of al-Shawt, 'Abdullah ibn Ubayy turned back with 300 of his followers. He justified his desertion with the words: “He obeyed them and ignored me. Why should we get ourselves killed, people?” This betrayal, the loss of a third of the army just before the battle, was a heavy blow. Only 700 Muslims remained to face the 3,000 Quraysh. Allah ﷻ revealed concerning this: “And that He might make evident those who are hypocrites”
Surah Aal-Imran (3:167).