Battle of the Trench (Khandaq)
Suggest editHistorical Background
The Battle of the Trench (غزوة الخندق), also known as the Battle of al-Ahzab (the Confederates), was fought in Shawwal 5 AH (March–April 627 CE). It was the largest military operation ever mounted against the Muslim community in Madinah. Following their defeat at Uhud, the Quraysh had not abandoned their determination to destroy Islam. They spent two years building a grand coalition — al-Ahzab (the Confederate parties) — with the explicit purpose of annihilating the Muslim state.
The coalition ultimately numbered approximately 10,000 warriors drawn from the Quraysh and their Kinana allies, the Ghatafan and their confederates from Najd, and smaller tribal contingents. They were coordinated significantly by Huyayy ibn Akhtab of the Banu Nadir, a Jewish tribe that had been expelled from Madinah for treachery, who was bitterly determined to see the Muslim community destroyed.
The Strategic Innovation: The Trench
When news of the advancing coalition reached Madinah, the Prophet ﷺ consulted his companions. Salman al-Farisi, a Persian companion who had converted to Islam, suggested digging a trench across the unprotected northern approach to Madinah — a military tactic well known in Persian warfare but entirely unfamiliar to the Arabs. The suggestion was immediately adopted.
Approximately 3,000 Muslims set to work digging the trench under extremely harsh conditions: bitter cold, extreme hunger, and the constant pressure of the approaching enemy. The Prophet ﷺ worked alongside the companions himself, carrying earth and breaking rocks. His companions later recounted his stamina and his words of encouragement during the work. The trench was completed — an extraordinary feat of collective labor — just before the confederate forces arrived.
The Siege and Divine Intervention
The ten-thousand strong confederate army found itself unable to cross the trench. Their cavalry, which was their primary military strength, was rendered useless against the obstacle. The siege stretched on for nearly a month. During this time, the confederates attempted multiple breaches, but were repelled. One of the fiercest moments came when the Arab warrior Amr ibn Abd Wudd managed to cross the trench with a small group. Ali ibn Abi Talib ؓ challenged and killed him in single combat, removing a significant threat.
More dangerous than the military threat was a diplomatic one: Huyayy ibn Akhtab had persuaded the Banu Qurayza, a Jewish tribe within Madinah who had a treaty with the Muslims, to break their agreement and threaten the Muslims from within. This created a two-front threat — the confederates outside and potential hostility from within — that placed enormous strain on the Muslim community. Allah describes the terror of those days: 'When they came upon you from above you and from below you, and when eyes were distorted [from fear], and hearts reached the throats, and you were assuming about Allah [various] assumptions' (Quran 33:10).
At the moment of greatest difficulty, Allah sent supernatural assistance. A fierce, cold wind (described as al-rih) battered the confederate camp, scattering their tents and supplies. Nu'aym ibn Mas'ud, who had secretly accepted Islam, sowed distrust between the Quraysh, the Ghatafan, and the Banu Qurayza through carefully crafted misinformation, causing each party to distrust the others. The fragile coalition collapsed from within.
Aftermath and Significance
The confederates withdrew without achieving their objective. The Prophet ﷺ prophesied immediately afterward: 'Now we will march against them, and they will not march against us' (Sahih al-Bukhari 4110). This proved to be a turning point in the entire Seerah. The initiative passed definitively from the Quraysh to the Muslims. Following the siege, the Banu Qurayza were held accountable for their treaty violation; Sa'd ibn Mu'adh, their former ally and the chief of the Aws tribe, was selected by both parties as arbitrator and issued the judgment according to the Torah's own ruling on treachery in wartime.
The Battle of the Trench demonstrated the wisdom of the Prophet ﷺ in adopting new military strategies, the extraordinary dedication of the companions, the power of unity, and above all the reality that Allah's help comes to the believers when they truly put their trust in Him.