That the foundations of this state needed continuous consolidation was very clear to the Prophet right from the beginning.
His initial major actions as he took charge in Madinah reflect his keen awareness of that need. He built the mosque, which was a place of worship, a people's assembly, and the palace of government, all in one.
He established a new and strong bond of brotherhood between his followers to consolidate the inner structure of his community. He also signed a treaty with the Jews to ensure peace in Madinah and to free himself to face outside threats, which were only to be expected.
The Quraish could not remain idle while the new state in Madinah acquired increasing strength. The Quraish was bound to conclude that the Islamic state in Madinah was going to challenge for supremacy inArabia.
It was expected that the Quraish might before long try to launch an all-out campaign to eliminate such a challenge before it had a chance to gather strength. A show of force by the Muslims in Madinah was therefore important, in order to make the Quraish think twice before embarking on any such hazardous course of action.
One may note here that up to the last few months of the Prophet's active work for Islam in Makkah, Muslims were commanded by God not to resort to arms in any confrontation with non-believers.
Several reasons may be advanced for such a policy. Firstly, the Makkan period was one of education of a certain people in a new tradition. The Muslim Arabs had to be trained not to retaliate for personal injury, but to look beyond their own persons and interests and to think first of their new community.
Secondly, the use of force in the Makkan period might have led to increased stubbornness on the part of the Quraish and, consequently, to a never-ending series of killing for vengeance. The blame for such an event would undoubtedly have been laid at the door of Islam.
Thirdly, the use of force might have led to numerous little family wars, as the believers still lived with their own families and clans. Since the Muslims were still small in number, they might have been totally exterminated.
Fourthly, the Muslims would have lost all the support of their clans. We have seen how the support of the Hashemites guaranteed for the Prophet all the protection he needed to continue his efforts in fulfillment of his mission.
As the Makkan period drew to an end, permission to fight the non-believers was given to the Prophet and his followers. This came in a Quranic verse which was revealed shortly before the Ansar made their second covenant with the Prophet.
No fighting, however, took place before the Prophet's emigration. There was every indication that it would come soon. Hence preparations for such an eventuality were called for.
The Muhajirun (Muslims who emigrated to Madinah) and the Ansar (Muslims who received the emigrants in Madinah) were good fighters. Almost every one of them had fought with his tribe. As already related, the two tribes to whom the Ansar belonged were involved in a fierce battle shortly before they came to know about Islam.
But all this experience was not quite enough for the Prophet's purposes. The Muslim
community would never fight a tribal war. A new army had to be built on a basis totally different from anything known in Arabia: the basis of faith.
Thus, the purpose of war would be different. The soldiers' attitude to death in battle would be based on the Islamic view that a martyr is certain to be admitted to heaven. His attitude to his fellow soldiers would also be completely different.
The Prophet wasted no time in building such an army. The Prophet had moved without a moment's delay to consolidate the foundations of his new state. Internally, the fabric of the social structure of the new society was of the highest quality.
Relations with other communities in Madinah were put on a sound basis. A well-trained army, which was soon to prove its caliber, was built up. The establishment of the new state was indeed a great achievement which crowned the Prophet’s hard work over the past 14 years.
Since Madinah was not an isolated city, its relations with its neighbors were highly important. All around Madinah there were Bedouin tribes which did not have much of an idea about Islam.
Independent though these tribes were, their natural sympathies were with the Quraish. Like the Quraish, they were pagans for whom religious values did not count for much. More importantly, the Quraish was still the recognized superpower in Arabia. Something had to be done to persuade those Arab tribes that things had changed.
Moreover, the Prophet's mission was universal. That is, he was commanded by God to make his message known to all mankind and to call upon them to believe in it. At no time did the Prophet envisage the establishment of the new state as his final objective.
It was simply the base from which he would move to explain his message to the rest of Arabia, and thence to the world at large. To achieve both objectives, the Prophet started to send out armed groups of his companions in what historians have called "saraya", which may be roughly translated as "expeditions".
Practically speaking, these were maneuvers through which the Muslims learnt a great deal about their enemies: their capabilities, their strong influence on other tribes and the depth of their feelings against the new state.
At the same time, these maneuvers enhanced the Muslims' fighting ability and enriched their knowledge of the surrounding area. The first expedition set out barely six months after the Prophet’s arrival in Madinah.
Thirty men from the Muhajirin, commanded by Hamzah, the Prophet's uncle, went towards the coast to stop a Quraish trading caravan. The leader of the caravan was none other than Abu Jahl, who had 300 men with him. No clash took place, as a tribal chief called Majdi ibn Amr of Juhaynah intervened to prevent it.
This expedition took place in Ramadan of the first year of the Islamic calendar. The following lunar month (Shawwal), the Prophet's companion, Ubaydah ibn Al-Harith, commanded a 60-man-strong expedition with the Prophet's instructions to go deep into the district of Rabigh, which was closer to Makkah than Madinah.
There, at a spring called Ahya', they met Abu Sufyan leading a Quraish force of 200 men. The two sides shot their arrows at each other but no direct fighting took place.
A few weeks later in Dhul-Qidah, Saad ibn Abu Waqqas was the commander of a 20-man-strong expedition which went on foot, travelling by night and hiding during the day. On the fifth day they arrived at a place called Al-Kharrar which was, according to their instructions, the furthest point they could reach. Having learnt that the Quraish caravan they were supposed to intercept had been a whole day ahead of them, they had to go back.
Nearly three months later, in Safar of the following year, the Prophet himself led a group of his companions and set out until he reached a place called Waddan. There he concluded a peace agreement with a tribe called Damrah. He met no enemy and went back. Having rested in Madinah for a short while, he set out again, leaving Abu Salamah to deputize for him in Madinah.
He went as far as al-Ashirah, close to Yanbu, where he stayed for a few days and made another peace agreement with the allied tribes of Mudlij and Damrah. He then went back to Madinah. Shortly afterwards, Kurz ibn Jabir of the Fihr tribe raided the grazing grounds on the outskirts of Madinah.
The Prophet himself chased him with a group of his companions up to the valley of Safwan, close to Badr. Kurz escaped. Historians call this chase the first Badr expedition.
As time passed, expeditions increased in frequency and significance.