Allah has mentioned in the Qur’an that He sent messengers and guides among all people. We Muslims believe in all Allah’s prophets and messengers who came before Prophet Muhammad (peace and blessings be upon him), who was the last prophet and messenger of Allah. It is not only the Prophet Muhammad but also all previous prophets and messengers mentioned in the Qur’an who should serve as role models for us. They provide us with inexhaustible sources of lessons and reminders for purposes of education, edification, and inspiration. So, our believing in the Prophet Muhammad (peace and blessings be upon him) as the last prophet and messenger of Allah does not or should not prevent us in any way from looking at the examples of other prophets and messengers and receiving inspiration and guidance from them.
Sheikh Ahmad Kutty, a senior lecturer and Islamic scholar at the Islamic Institute of Toronto, Ontario, Canada, states: While it is true that Prophet Muhammad is the final messenger of Allah (may Allah bless him and grant him peace), with whom prophecy comes to a full circle, and his role model is the perfect role model for us to emulate at all times, this, however, does not or should not prevent us in any way from looking at the examples of other prophets and messengers and receiving inspiration and guidance from them. In fact, it is precisely for this reason the Qur’an narrates their stories for us so that we may constantly reflect and meditate upon them and thus be spiritually molded by them.

the Qur’an is the word of God; it is the ultimate source of guidance, healing, mercy, and illumination for humanity. Being God’s own work, the Qur’an has nothing superfluous or redundant in the Qur’an, and, as such, each and every verse therein, and each and every story, parable, or instance narrated or mentioned in it—irrespective of whether it has been related of Prophet Muhammad or any of the previous prophets or messengers or sages or anyone else for that matter—is worthy of prolonged reflection. They provide us with inexhaustible sources of lessons and reminders for purposes of education, edification, and inspiration.
When considered in this way, it is not only the Prophet Muhammad but also all previous prophets and messengers mentioned in the Qur’an who shall serve as role models for us. In fact, Prophet Muhammad’s mission encompasses the mission of all prophets; it not only completes their mission but also encompasses and comprehends them all. As Imam Shah Waliullah has stated, the risalah (mission) of Prophet Muhammad (peace and blessings be upon him) is comprehensive in the sense that it encompasses within its purview the message and mission of all previous prophets; thus it contains within itself, for instance, the Law of Moses as well as the way of Jesus.
this is why while narrating the stories of previous prophets and messengers the Qur’an makes it abundantly clear in no uncertain terms that these stories are told not for sake of entertainment but as a source of perennial guidance and wisdom: (Indeed in their stories [that is, the stories of the prophets] there is a lesson for men of understanding. This (Qur’an) is no invented tale but a confirmation of the previous (books), a detailed explanation of all things, a guidance and a mercy to people who believe) (Yusuf 12:111).
Let us now come to specific examples: The Qur’an mentions a number of prophets such as Nuh, Ibrahim, Lut, Isma`il, Ishaq, Ya`qub, Yusuf, Musa, `Isa, and Ayyub. While narrating their stories the Qur’an frequently reminds us that such narrations are not merely for entertainment; rather, they are primarily intended to teach us valuable lessons that have direct bearing on our own daily struggles with faith and practice. Thus by reflecting on the story of Prophet Ibrahim (peace and blessings be upon him), we can learn the dynamic nature of faith, trust, struggle, and sacrifice as unfolded in the story. Prophet Ibrahim is thus held out as a true role model for humanity. Prophet Muhammad (peace and blessings be upon him) and his followers, as well as the followers of all prophets, are told to emulate his examples.
Likewise, there are valuable lessons for us in the story of Musa, whose mission was to liberate the children of Israel from the slavery of Pharaoh. Liberation of humanity is at the heart of the mission of Prophet Muhammad (peace and blessings be upon him) as perceived by his own Companions. The words of Rab`i ibn `Aamir to the Persian commander, “Our mission is to liberate humanity from slavery of men to the servitude of Allah!”, are worth remembering in this context. Look at the irony of Pharaoh killing all the male children of Israel in order to stave off and subvert the coming of Prophet Musa (peace and blessings be upon him) while Allah makes Pharaoh care for Musa with his own hands in such a way that Pharaoh himself nurtures the person who will eventually challenge his authority. This is a lesson for all mortals to remember: that no matter how hard we may seek to outsmart Allah, eventually we will be defeated by Allah as our plans may ultimately fall tumbling on us.
Similarly, the beautiful story of Prophet Yusuf (peace and blessings be upon him), serves as an unending source of wisdom for the Prophet (peace and blessings be upon him) as well as the faithful. It teaches us how we must never get carried away by the surface events but must have the patience to discern the subtle hands of God as He directs the myriad events and forces of history. For who would have imagined that the boy who was cast into the pit, sold into slavery, and then dumped in the dungeon will ultimately beat all the odds and would be elevated to become the undisputed master of Egypt presiding over the destinies of those very people who had persecuted him? This story is narrated first to the Prophet Muhammad (peace and blessings be upon him) in such a way that each and every twist and turn in the story has a parallel in his own story as it was unfolding before his own eyes and the eyes of those who first read it. Wasn’t Prophet Muhammad the favourite of his own people even as Prophet Yusuf was the favourite of his father? Wasn’t he expelled like Yusuf from his own home and country? Didn’t he, after many years of trials and tribulations, master all odds and triumph over those who had persecuted him? In fact, Prophet Muhammad (peace and blessings be upon him), at the final moment of victory over his enemies who had persecuted him, used the very same words that Prophet Yusuf (peace and blessings be upon him) used in addressing his enemies: “Today, I shall not blame anyone of you. Rather I will only say to you what Prophet Yusuf told his tormenters, ‘You are all free to go!’” Still in a more general sense, this story of Yusuf has parallels in the history of every believer as he goes through the daily struggles of life.
the same can be said about all the stories narrated by the Qur’an. They all reflect the same struggles, trials, and tribulations faced by people of faith at all times and places. They reveal the workings of Allah in history, which we may fail to recognize when totally preoccupied as we are in the myriad cares and concerns of superficial living. But the purpose of the Qur’an is to make our spiritual discernment so sharp and intense that we are ever enabled to decipher the signs of Allah in nature, history, and our own lives as they unfold.
In conclusion: All prophets and messengers whose stories have been narrated in the Qur’an serve as role models and sources of inspiration for the faithful. The fact that Prophet Muhammad (peace and blessings be upon him) is the final messenger does not in the least detract from this fact; for as a matter of fact, his mission is a confirmation of the same perennial message revealed to all prophets and messengers from Adam to `Isa (peace and blessings be upon them all). Thus Qur’an says, (We made of them leaders, guiding others by Our command, and We inspired them to do good works, to be constant in Prayer, and to give alms: they were Our true worshipers.) (Al-Anbiya’ 21:73); (And We made some of them leaders who guided by Our command, when they were patient and had certitude in Our signs) (As-Sajdah 32:24).