After the excursus on Judah and Tamar, the narrative returns to Joseph, a slave in Egypt to Potiphar (Genesis 39:1). Potiphar is referred to as the “captain of the guard” (verse 1). Egyptologist John Gee suggested that this was equivalent to the Egyptian title sḥḏ šmsw, meaning “controller of guards.” “This is not an elite position but probably the equivalent of upper middle class,” according to Gee. He would thus be “wealthy enough to own a few slaves, including Joseph and some others whose presence is only mentioned.”
Despite his unideal circumstances, Joseph was blessed by the Lord and prospered as a slave in Potiphar’s house (verses 2–3). Potiphar thus appointed Joseph as “overseer” of his household (verses 4–5). James K. Hoffmeier noted that Egyptian documents from this time period show Semitic servants with the title ḥry-pr, which literally means “he who is over the house.” Joseph may have been promoted to the even higher status of imy-re-pr, often translated as “steward” or “chamberlain” but which also means something like “overseer of the house” according to Hoffmeier.
The story of Potiphar’s wife attempting to seduce Joseph appears to be based on an Egyptian type scene, as illustrated in the similar story found in the “Tale of Two Brothers,” which dates to around the thirteenth century BC. In both stories, a servant finds himself alone in the house with his master’s wife, who then bluntly invites the servant to lie with her; the servant declines the proposition with an extended speech, after which the woman defames him to her husband and claims the servant attempted to force himself on her.
As expected, when comparing various versions of a type scene, differences are as important as similarities. In the “Tale of Two Brothers,” details are exaggerated and fanciful, illustrating the fictional nature of the story, while the Joseph story reflects a more sober and realistic account befitting of historical narrative. Both stories also involve a garment, though in the Egyptian tale, the master’s wife offers to make the servant a garment if he gives in to her demand. In contrast, in the biblical story Joseph’s garment is seized from him and used as evidence against him (Genesis 39:12–18).
The most important difference, however, is reflected in Joseph’s response to Potiphar’s wife. In the “Tale of Two Brothers,” the servant “becomes angry and fierce, like a wild animal,” in refusing the proposition of his master’s wife. In contrast, Joseph remains calm and concludes with an appeal to divine morality: “How then can I do this great wickedness, and sin against God?” (verse 9). As John Gee noted, “While the Egyptian account features ferocity, the biblical account promotes piety.” Jewish scholar Nahum Sarna further explained:
Probably nothing is more indicative of the wide chasm separating Israel from its neighbors than the line of argument used by Joseph in rejecting the repeated entreaties of the would-be adultress. . . . This plea of Joseph expresses [a] distinctive biblical concept of morality. Adultery is a sin against God. It is not a matter of social impropriety or breach of convention, not just an indignity to the husband or an outrage upon society. It is a religious offense in which God is vitally involved. In other words, the sanction of morality is divine, not social, and for this reason morality is absolute and not relative.
Adultery had a wide range of possible punishments in ancient Egypt: “Adultery . . . could be punished by throwing the adulterer or adulteress to the crocodiles, setting them on fire, killing them, beating them up, or fining them,” among other possibilities. All things considered, “Joseph’s punishment for a crime he did not commit was comparatively mild,” especially when his social status as a slave is taken into account. One scholar has suggested that this relatively lenient punishment may indicate that Potiphar did not fully believe his wife’s account.
Going from slave to prisoner seems like a “further degradation for Joseph, a step worse than slavery.” But once again, the Lord was with Joseph and blessed him to prosper despite these undesirable circumstances (Genesis 39:21–23). Joseph’s imprisonment “actually moves him closer to triumph and the fulfillment of his childhood dreams.”
Because of the Lord’s blessings, Joseph was placed in a position as an overseer in the prison, just as he was previously in Potiphar’s house (Genesis 39:21–23). While Joseph was in prison, two officials from Pharaoh’s court were also imprisoned: the “chief of the butlers” and the “chief of the bakers,” and Joseph was placed as their overseer (40:1–4). The chief butler (or “cupbearer”) was often a highly trusted advisor to the king and, in some cases, even acted as a judge. Meanwhile, the chief baker in the royal household was most likely skilled in preparing “all manner of bakemeats” (verse 17), which included more than fifty different types of bread and almost forty varieties of cake, according to Egyptian records.
Each of these officials had a dream and was distressed because they could not access the professional class of dream interpreters from prison. Since dreams were often believed to convey a divine message in the ancient world, not knowing the proper interpretation could induce anxiety. In Egypt, “dream interpreters consulted manuals . . . [wherein] the situation in the dream is described, classified as either good or bad, and is then interpreted as a sign of what will happen in the future.” Joseph, however, declared that “interpretations belong to God” (verse 8) and proceeded to interpret their dreams without the aid of a manual.
Ancient dream manuals do not provide any exact matches to the butler’s and the baker’s dreams (verses 9–19), but they do include dreams with similar details, which might provide a clue as to “how Egyptians would have interpreted them and give us an idea of what might have made sense to them.” Dreams about drinking wine were indicative of righteous living, and pressing wine meant a person would receive what was rightfully theirs. Joseph’s interpretation of the butler’s dream essentially aligns with these interpretations and “would have seemed like a reasonable interpretation” to an ancient Egyptian. Thus, it would have been “comforting in both its content and style of presentation” to the butler, who was evidently found innocent and restored to his status (verses 13, 21).
The apparent reasonableness of Joseph’s interpretation may have strengthened the baker’s confidence in Joseph’s ability (verse 16). Dreams of white bread, such as the baker’s, were expected to have positive connotations, based on the Egyptian dream manuals. Yet the baker’s dream was not good: in three days he was removed from prison and put to death (verses 19, 22). Thus, the narrative builds up and then subverts expectations, giving the baker—and readers familiar with Egyptian dream interpretation—reason to expect a positive outcome, only to dash those expectations by announcing his demise.
There is a spiritual lesson to be learned from this as well. As John Gee noted, “Joseph’s interpretations from the Lord did not necessarily match those that Egyptian sages gave because while God is willing to speak to individuals so that they might come to understanding (Doctrine and Covenants 1:24), there would be no need for divine intervention if God only told us what our culture or own desires already told us.”
 John Gee, “Clothes and Cups: The Tangible World of Joseph,” in From Creation to Sinai: The Old Testament through the Lens of the Restoration, ed. Daniel L. Belnap and Aaron P. Schade (Salt Lake City, UT: Deseret Book; Provo, UT: Religious Studies Center, Brigham Young University, 2021), 430.
 James K. Hoffmeier, Israel in Egypt: The Evidence for the Authenticity of the Exodus Tradition (New York, NY: Oxford University Press, 1996), 84.
 Hoffmeier, Israel in Egypt, 84; Gee, “Clothes and Cups,” 430–431.
 John Gee, “Clothes and Cups: The Tangible World of Joseph,” in From Creation to Sinai: The Old Testament through the Lens of the Restoration, ed. Daniel L. Belnap and Aaron P. Schade (Salt Lake City, UT: Deseret Book; Provo, UT: Religious Studies Center, Brigham Young University, 2021), 431–432; Victor H. Matthews and Don C. Benjamin, eds. and trans., Old Testament Parallels: Laws and Stories from the Ancient Near East, 3rd ed. (Mahwah, NJ: Paulist Press, 2006), 65–69.
 Gee, “Clothes and Cups,” 432–437; Nahum M. Sarna, Understanding Genesis through Rabbinic Tradition and Modern Scholarship (New York, NY: Melton Research Center, Jewish Theological Seminary of America, 1966), 215–217.
 Gee, “Clothes and Cups,” 432–433.
 Gee, “Clothes and Cups,” 436.
 Gee, “Clothes and Cups,” 436.
 Sarna, Understanding Genesis, 217.
 John Gee, “Clothes and Cups: The Tangible World of Joseph,” in From Creation to Sinai: The Old Testament through the Lens of the Restoration, ed. Daniel L. Belnap and Aaron P. Schade (Salt Lake City, UT: Deseret Book; Provo, UT: Religious Studies Center, Brigham Young University, 2021), 437.
 Gordon J. Wenham, “Genesis,” in Eerdmans Commentary on the Bible, ed. James D. G. Dunn and John W. Rogerson (Grand Rapids, MI: Eerdmans, 2003), 66.
 Wenham, “Genesis,” 66.
 Wenham, “Genesis,” 66.
 Nahum M. Sarna, Understanding Genesis through Rabbinic Tradition and Modern Scholarship (New York, NY: Melton Research Center, Jewish Theological Seminary of America, 1966), 218; Nili Shupak, “A Fresh Look at the Dreams of the Officials and of Pharaoh in the Story of Joseph (Genesis 40–41),” Journal of the Ancient Near Eastern Society 30 (2005): 128–129.
 Sarna, Understanding Genesis, 218; Shupak, “Fresh Look,” 129–130.
 Sarna, Understanding Genesis, 212–213.
 John Gee, “Clothes and Cups: The Tangible World of Joseph,” in From Creation to Sinai: The Old Testament through the Lens of the Restoration, ed. Daniel L. Belnap and Aaron P. Schade (Salt Lake City, UT: Deseret Book; Provo, UT: Religious Studies Center, Brigham Young University, 2021), 439.
 Gee, “Clothes and Cups,” 439.
 Gee, “Clothes and Cups,” 440.
 See Genesis 40:16, particularly in the American Standard Version, New American Standard Bible, and New English Translation. See also Shupak, “Fresh Look,” 132–133.
 Gee, “Clothes and Cups,” 440–441.