Yusuf (, ) is a prophet and messenger of God mentioned in the Qur'an and corresponds to Joseph, a person from the Hebrew and Christian Bible who was said to have lived in Egypt before the New Kingdom. Amongst Yaqub's children, Yusuf reportedly had the gift of prophecy through dreams. Although the narratives of other prophets are presented in a number of surah, Yusuf's complete narrative appears in only one: Yusuf. Said to be the most detailed narrative in the Quran, it mentions details that do not appear in its biblical counterpart.

Yusuf is believed to have been the eleventh son of Ya'qub () and, according to a number of scholars, his favorite. Ibn Kathir wrote, "Yaqub had twelve sons who were the eponymous ancestors of the tribes of the Israelites. The noblest, the most exalted, the greatest of them was Yusuf." The narrative begins with Yusuf revealing a dream to his father, which Yaqub recognizes. In addition to the role of God in his life, the story of Yusuf and Zulaikha (Al-Aziz(Potiphar)'s wife in the Old Testament) became a popular subject of Persian literature and was elaborated over centuries.

In the Qur'an

The story of Yusuf in the Qurʾān is a continuous narrative in its twelfth chapter, named Surah Yusuf (). There are over one hundred verses in this chapter, encompassing many years; they "present an amazing variety of sciences and characters in a tightly-knit plot, and offer a dramatic illustration of some of the fundamental themes of the Qurʾān." The Qur'an notes the story's importance in the third verse: "and We narrate unto you ()" (Qur'an, 12:3). Most scholars believe that this refers to Yusuf's story; others, including al-Tabari, believe that it refers to the Qur'an as a whole. It documents the execution of God's rulings despite the challenge of human intervention ("And God hath full power and control over His affairs; but most among mankind know it not").

Before the dream Muhammad al-Ṭabari provides detailed commentary on the narrative in his chapter on Yusuf, relaying the opinions of other well-known scholars. In al-Ṭabari's chapter, the physical beauty of Yusuf and his mother Rahyl is introduced; they were said to have had "more beauty than any other human being." His father, Yaqub(Yaqub), had given him to his (Yaqub's) oldest sister to be raised. Al-Ṭabari writes that there was no greater love than what Yusuf's aunt felt for him, since she raised him as her own; reluctant to return him to Yaqub. According to al-Ṭabari, she could do this because of a belt given to her by her father, Is-haq(Issac) (Isaac): "If someone else acquired it by guile from the person who was supposed to have it, then he would become absolutely subject to the will of the rightful owner." Yusuf's aunt puts the belt on Yusuf when Yaqub is absent; she accuses Yusuf of stealing it, and he remains with her until her death. Yaqub is reluctant to give Yusuf up, and favors him when they are together.

The dream The narrative begins with a dream, and ends with its interpretation. As the sun appeared over the horizon, bathing the earth in morning glory, Yusuf (son of Yaqub) awakens delighted by a pleasant dream. Filled with excitement, he runs to his father and reports what he saw.

According to Ibn Kathir, Yaqub knows that Yusuf will become important in this world and the next. He recognizes that the stars represent his brothers; the sun and moon represent himself and Yusuf's mother, Rahyl(Rachel) (). Yaqub tells Yusuf to keep the dream secret to protect him from the jealousy of his brothers, who are unhappy with Yaqub's love for Yusuf. He foresees that Yusuf will be the one through whom the prophecy of his grandfather, Ibrahim, would be fulfilled: his offspring would keep the light of Abraham's house alive and spread God's message to mankind. Abu Ya'ala interpreted Yaqub's reaction as an understanding that the planets, sun, and moon bowing to Yusuf represented "something dispersed which God united." Yaqub tells Yusuf, "My son, relate not thy vision to thy brothers, lest they concoct a plot against thee: for Satan is a clear enemy to humanity. Thus your Lord has selected you and given you the knowledge to interpret dreams, and has perfected His blessing upon you and upon the family of Yaqub just as He perfected it on your forefathers before: Ibrahim and Is-haq (Isaac). Your Lord is Knowing, Wise" (Qur'an, Surah 12 (Yusuf) Ayat 56).

Yusuf does not tell his brothers about his dream (unlike the Hebrew Bible version), but they remain very jealous. Al-Ṭabari writes that they said to each other, "Verily Yusuf and his brother (Binyamin) are dearer to our father than we are, though we may be a troop (). By 'usbah () they meant a strong group, for they were ten in number. They said, "Our father is plainly in a state of aberration." Yusuf has a gentle temperament and is respectful, kind, and considerate, like his brother Binyamin (); both are Rahyl(Rachel)'s sons. From amongst the (), one states:

Plot against him

The Qur'an continues with Yusuf's brothers plotting to kill him: "In Yusuf and his brothers are signs for those who seek answers" (Qur'an, 12:7). Yusuf's brothers said about him: "He is more loved by our father than we are, and we are a group. Our father is in clear error. Let us kill Yusuf or cast him to the ground, so that your father's face will be toward you, and after him you will be a community of the truthful". One brother argues against killing him and suggests throwing him into a well (said to be ()), where a caravan might rescue and enslave him: "Slay not Yusuf, but if ye must do something, throw him down to the bottom of the well: he will be picked up by some caravan of travelers". Islamic scholar Mujahid ibn Jabr identifies the brother as Simeon. Another scholar, al-Suddi, identifies him as Judah, and Qatada ibn al-Nu'man writes that it was the eldest, Reuben. Scholars suggest that Yusuf may have been as young as twelve when he was thrown into the well. He would live to be 110 or 120.

The brothers ask their father to let them take Yusuf into the desert to play, and promise to watch him. Yaqub hesitates, aware of their resentment towards their brother. Yaqub's excuse is that a wolf () might hurt him while they are not paying attention. The brothers insist on their strength, calling themselves losers if they are not able to protect Yusuf. With their father convinced, they throw Yusuf into a well. They return with a blood-stained shirt, saying that he had been attacked by a wolf, but unlike in the biblical narrative, Yaqub does not believe them. According to the Quran

Al-Ṭabari writes that Judah stops the brothers from further harming Yusuf, and brings him food. Ibn Kathir writes that Reuben suggested that they put him in the well so he could return later to bring him home. When he returns, Yusuf is gone: "So he screamed and tore his clothes. He put blood on the coat of Yusuf. When Yaqub learned of this, he tore his clothes, wore a black cloak, and was sad for many days". Ibn Abbas writes that the "reason for this trial of Yaqub was that he had slaughtered a sheep while he was fasting. He asked a neighbor of his to eat it but he did not. So God tested him with the matter of Yusuf." He interprets Yusuf's revelation in the well: "When they were unaware" (12:15) means "you will tell them about what they did in a situation in which they will not recognize you." A possible reason for Yusuf's enslavement was that after Abraham left Egypt with slaves, "Abraham did not dismount for them (following barefoot). Therefore God revealed to him: 'Since you did not alight for the slaves and those walking barefoot with you, I will punish you by selling one of your descendants into his country.

Divine intervention

A passing caravan takes Yusuf after it stops by the well to draw water and sees the boy inside. The brothers, nearby, sell Yusuf for a very low price, only wanting to get rid of him. The caravan rescue him and sell him into slavery in Misr (, Egypt), to a rich man, the King’s vizier, known as Al-'Aziz () in the Quran and Potiphar in the Bible.Genesis, 'Aziz is also known as Qatafir or Qittin. Yusuf is taken into 'Aziz's home, and the man tells his wife to treat him well.

Scholars of Islam cite this point as central to Yusuf's story. Yusuf rises to a high position in Al-'Aziz's household and, when his brothers later come to Egypt, they do not recognize him. He reaches manhood, and 'Aziz's wife tries to seduce him. Al-Tabari and others note that Yusuf is also attracted to her, and al-Ṭabari writes that he does not succumb to her because when they were alone, the "figure of Yaqub appeared to him, standing in the house and biting his fingers ... God turned him away from his desire for evil by giving him a sign that he should not do it."

Zulaikha, the wife of Al-'Aziz, rips the back of Yusuf's shirt as they race one another to the door where her husband is waiting. She tries to blame Yusuf, suggesting that he had attacked her, but Yusuf's account of Zulaikha's attempted seduction is confirmed by a member of the household; Azīz believed Yusuf and told his wife to beg forgiveness." The household member tells 'Aziz to check Yusuf's shirt. If the front is torn, Yusuf is guilty; if the back is torn, Zulaikha is guilty. The shirt is torn in the back, and 'Aziz reprimands his wife for lying.

Zulaikha's friends think that she is infatuated with Yusuf, and ridicule her for falling in love with a slave. She invites them to her home, and gives them apples and knives to peel them with. Zulaikha then has Yusuf walk through the room; the women are so distracted by his handsomeness that they cut their fingers with the knives, and she says that she sees Yusuf every day. Yusuf prays, saying that he would prefer prison to succumbing to Zulaikha and her friends. According to al-Ṭabari, 'Aziz later "grew disgusted with himself for having let Yusuf go free ... It seemed good to them to imprison him for a time." The popular story of Yusuf and Zulaikha differs in the Quran from the Biblical version, in which Potiphar believes his wife and imprisons Yusuf.Genesis, According to some scholars, after 'Aziz's death, Yusuf reportedly marries Zulaikha.

Dream interpretation This account refers to the interaction between Yusuf and the ruler of Egypt. Unlike references to the pharaoh in the account of Moses, the story of Yusuf refers to the Egyptian ruler as a king () rather than a pharaoh (). After Yusuf had been imprisoned for a few years, God gives Yusuf the ability to interpret dreams, a power which makes him popular amongst the other prisoners. Before his imprisonment, two royal servants had been thrown into the dungeon for attempting to poison the food of the king and his family. Yusuf asks them about their dreams; one says that he saw himself pressing grapes into wine, and the other that he saw himself with a basket of bread on his head that birds are eating from. Yusuf says that the first servant will be released and return to the side of the king, but the second will be executed; both came to pass.

He asks the servant who will be released (Nabu, according to al-Ṭabari) to mention his case to the king. Asked about his time in prison, al-Ṭabari writes that Muhammad said: "If Yusuf had not said thatmeaning what he said (to Nabu)he would not have stayed in prison as long as he did because he sought deliverance from someone other than God."

The king is frightened by his dream that seven fat cows were eaten by seven thin ones and seven ears of corn were replaced with shriveled ears; none of his advisors could interpret it. When the servant who was released hears about it, he remembers Yusuf and persuades the king to send him to Yusuf for an interpretation. Yusuf tells the servant that Egypt will face seven years of prosperity followed by seven years of famine, and the king should prepare for it.