It is unanimously agreed upon, by historians, legal specialists and theologians of all groups, that the Prophet (Ṣallāhu ‘alayhi wa salam) himself never commanded his followers to celebrate his birthday, nor was this practice known for the first few centuries of Islām. Therefore, the question arises as to how this practice was instituted and who were the first group to think of the idea of celebrating the birthday of the Prophet (Ṣallāhu ‘alayhi wa salam).
The Origin of the Mawlid
The first mention ever made of the mawlid celebrations in any historical work comes in the writings of Jamāl al-Dīn Ibn al-Ma’mūn, who died 587 AH/1192 CE. His father was the Grand Vizier for the Fatimid Caliph al-Amir (ruled 494-524 /1101-1130). Although the work of Ibn al-Ma’mūn is now lost, many parts of it were quoted by later scholars, in particular the most famous medieval historian of Egypt, al-Maqrīzi (d. 845/1442) in his monumental Mawā’īẓ al-i’tibār fī khiṭaṭ Miṣr wa-l-amṣār (shortened to the Khiṭaṭ). Al-Maqrīzi’s book is the standard source of information for Fatimid and early Mamlūk Egypt. What makes this work stand out above many others is not only its comprehensiveness, but also the fact that al-Maqrīzī quotes from many earlier references that are now lost, and also takes great care to cite his source, a practice very rare for the time.
Al-Maqrīzī relies upon the work of Ibn al-Ma’mūn for information regarding the social, political and religious policies of the Fatimids during the early part of the sixth century, which was the period that Ibn al-Ma’mūn’s father worked for the Fatimid Caliph. Due to the high position that his father enjoyed, Ibn al-Ma’mūn provided many details that outside historians could not possibly have been privy to.
Before proceeding, it is important to point out some facts regarding the Fatimid dynasty. This dynasty had established itself as a rival dynasty to the Abbasids in Baghdad. They had conquered Egypt in 358/969, and established the modern city of Cairo. They claimed descent from the Family of the Prophet (a claim that all others deemed to be fabricated), and followed the Sevener Branch of Shi’ite Islām, also known as ‘Ismailism’. Their beliefs and customs were so different from other branches of Islām that all Sunnis and even many other non-Ismaili Shi’ite groups deemed them outside the fold of the religion. The Ismailis had reinterpreted the five pillars of Islām to such a level that they would not conform to the regular rituals that other Muslims are accustomed to (such as the five daily prayers). The intellectual (and at times even biological) descendants of the Fatimid caliphs in our times are many. In particular, the Ismaili Aga Khan Imams and the Bohri Imams both trace their direct lineage to the Fatimid caliphs, and the group known as the Druze also are an offshoot of the Fatimid dynasty. It was this dynasty that first initiated the celebration of the mawlid.
To return to our topic, Al-Maqrizi, in his Khiṭaṭ, quotes Ibn al-Ma’mūn as follows, writing about the events of the year 517:
Next, the month of Rabī’ al-Awwal arrived, and we shall begin [the events of this month] by mentioning the thing for which it has become famous, namely, the birthday of the Master of the first and last, Muḥammad, on the thirteen [sic.] day. And by way of charity, the Caliph presented 6000 dirhams from the fund of najāwa [an Ismailite tithe], and from the dar al-fitra he presented 40 dishes of pastry, and from the chambers of the trustees and caretakers of the mausoleums that lie between the Hill and Qarafa, where the Al al-Bayt lie, he gave sugar, almonds, honey, and sesame oil [as a gift] to each mausoleum. And [his Vizier] took charge of distributing 400 pounds (ratl) of sweets, and 1000 pounds of bread.
The wording of the paragraph clearly suggests that the mawlid was a clearly established practiced by this time.
Another early source that mentions the mawlid is the work of Ibn al-Ṭuwayr (d. 617/1220), in his work Nuzhat al-Muqlatayn fī Akhbārt al-Dawlatayn. Ibn al-Ṭuwayr worked as a secretary for the Fatimid dynasty, and witnessed the change of power from the Fatimids to the Ayyubids, at the hand of Salaḥ al-Dīn al-Ayyūbi, which occurred 567/1071. His skills were so appreciated that he ended up working for the government of Ṣalāh al-Dīn as well. Ibn al-Ṭuwayr also describes the pageantry and pomp associated with the mawlid. He describes in detail  the large amounts of foods that were distributed on this day, especially around the famous mausoleums of Cairo (some of which would have been considered by the Fatimids as being those of their Imams). The focus of the pageantry, of course, was the palace of the Caliph, and only the elite would get to attend. The celebrations of the day worked their way up to the appearance of the Caliph (who was the living imām for the Ismailites) from a palace window, his face covered in a turban. He himself would not deign to speak – rather, his private attendants would signal to the audience that the Caliph had returned their greetings and seen their love for him. From the courtyard pavilion various reciters and preachers would address the audience, finally culminating in the address of the khatib of the Azhar masjid (which of course, at that time, was the epitome of Ismaili academics).
The mawlid was not the only celebration that was sponsored by the Fatimids. Al-Maqrīzi, in his Khiṭaṭ,  has an entire section dedicated to Fatimid holidays. He writes, under a chapter heading entitled, “The mentioning of the days that the Fatimid Caliphs took as celebrations and festivals throughout the year, upon which the situation of the people would be improved and their benefits increased,”
The Fatimid Caliphs had, throughout the year, a number of festivals and celebrations. These were: 1. New Year’s Eve, 2. Beginning of the year celebrations, 3. The Day of ‘Āshūrā’, 4. The birthday of the Prophet (Ṣallāhu ‘alayhi wa salam), 5. The birthday of ‘Alī, 6. The birthday of al-Ḥasan, 7. The birthday of al-Husayn, 8. The birthday of Fāṭima al-Zahrā’, 9. The birthday of the current Caliph, 10. The first day of Rajab, 11. The fifteenth day of Rajab, 12. The first day of Sha’bān, 13. The fifteenth day of Sha’bān, 14. The festival of Ramaḍān, 15. the first day of Ramaḍān, 16. The middle of Ramaḍān, 17. The end of Ramaḍān, 18. The Night of the Khatm, 19. The Day of ‘Īd al-Fitr, 20. The Day of ‘Īd of Sacrifice, 21. The Day of ‘Īd al-Ghadīr, 22. The ‘Cloth of Winter’, 23. The ‘Cloth of Summer’, 24. The Day of the ‘Conquest of the Peninsula’, 25. The Day of Nawrūz [Persian festival], 26. The Day of Veneration [Christian], 27. Christmas [Christian], 28 Lent [Christian]
As can be seen, the Fatimids loved their celebrations! The reason why they had so many celebrations is obvious, and is hinted at by al-Maqrīzi in his title. As the main rival to the ‘Abbāsid dynasty, the Fatimids were desperate to try to legitimize their rule in the eyes of the masses, and one of the ways to do so was to shower them with gifts on these days, and to provide an outlet for them to be merry and enjoy. Al-Maqrīzi mentions in detail the types of gifts that would be showered on the people on each of these days, sometimes exotic dishes of meat and bread, most of the time pastries and sweets, and even (on the ‘Cloth’ days) special types of clothes. Anyone who has been to Cairo can attest to the pomp of Fatimid structures, but it wasn’t only through architecture that the Fatimids wished to prove their superiority over the Abbasids.
Another thing to note is that there are many pagan festivals listed as well, for the Zoroastrian and Christian citizens. All of this was done to appease these minorities and prevent them from rebelling against the state.
A number of factors need to be discussed here.
1) From the above, it appears that the Faṭimids instituted a number of key yearly celebrations, all of which involved much pomp and pageantry. The primary celebrations were the mawlids of the Prophet and Imams, and also the celebration of the day of Ghadīr Khumm (the day that Shi’ites of all stripes believe the Prophet designated ‘Alī b. Abī Ṭālib to be the heir apparent). As mentioned earlier, the primary purpose of so much pageantry was to ingratiate themselves with the masses. Such public celebrations would have been anticipated as public holidays, and as days to revel and enjoy good food and sweets, compliments of the government.
2) We can also venture a rough guess regarding the era that the mawlid was introduced. Without any other sources, it is impossible to reconstruct a precise date on which the Faṭimids initiated the mawlid. However, recall that al-Maqrizī’s history (the Khiṭat) is merely a compilation of numerous histories that are now missing. Many of these histories, such as those of Ibn al-Ma’mūn and Ibn Ṭuwayr, were written by eyewitnesses. Modern scholars have analyzed the sources of al-Maqrīzi’s history, and shown that for each era, al-Maqrizī relied on specific authors. For events of the third, fourth and fifth centuries, al-Maqrizī took from authors of other works; it was only for events of the sixth century that he quoted Ibn al-Ma’mūn. Therefore, since the first suggestion of the mawlid occurs in the chronicles of Ibn al-Ma’mūn, we can safely venture the hypothesis that the mawlid was first celebrated around the turn of the sixth hijrī century.
3) All of the mawlids introduced by the Fatimids centered around the Family of the Prophet, except for the mawlid of the Prophet (Ṣallāhu ‘alayhi wa salam) himself. The Shi’ite nature of the Fatimid Dynasty, along with the other celebrations that were practiced, makes it quite clear that the entire concept of celebrating birthdays was a Shi’īte one aimed at exalting the status of the Imams. In fact, these source books mention that on the days of these other mawlids, most of the ceremonies took place around the mausoleums and graves of the Fatimids, and it was at these places where much of the food was distributed. Hence, the Fatimids clearly wished to promote the cult of the Imams and ‘Ahl al-Bayt’, and aggrandize their religious figures. When the Fatimid dynasty collapsed, the other mawlids were simply forgotten, as they held no significance for Sunnis, but the mawlid of the Prophet (Ṣallāhu ‘alayhi wa salam) continued. In other words, the mawlid was originally an Isma’ili Shi’ite festival, even though eventually it lost the tarnish of its Shi’ite origins.
4) The earliest reference (that of Ibn al-Ma’mūn) specifically states that the mawlid was celebrated on the 13th of Rabi’ al-Awwal. Scholars have said that this is either an error (and what proves this is that the later Ibn al-Ṭuwayr correctly writes that it was celebrated on the 12th of Rabī’ al-Awwal), or that it was initially instituted on the 13th, but within a generation was changed to the 12th. In either case, by the middle of the sixth century, the mawlid was an official holiday in Fatimid Egypt.
The question then arises: how did the mawlid spread to Sunni lands, and who was the first to introduce it to lands East and West of Fatimid Egypt? That shall be the topic of the third and final part to this article, insha Allāh.
 See: Nuzhat, p. 217-219  vol. 1, p. 490  The modern Egyptian author Hasan al-Sandubi, in the only monograph in Arabic on the subject, suggests that the Fatimid Caliph al-Mu’izz was the first to initiate this celebration, but there is absolutely no evidence that he brings to back this claim. Al-Mu’izz ruled from 341 to 365 A.H.  See the editor’s introduction to Nuzhat al-Muqlatayn, p. 3, where he lists al-Maqrizī’s sources for every era.