Jacob settles in Hebron with his twelve sons. His favorite is 17-year-old Joseph, whose brothers are jealous of the preferential treatment he receives from his father, such as a precious many-colored coat that Jacob makes for Joseph. Joseph relates to his brothers two dreams he has which foretell that he is destined to rule over them, increasing their envy and hatred towards him.
Shimon and Levi plot to kill him, but Reuben suggests that they throw him into a pit instead, intending to come back later and save him. While Joseph is in the pit, Judah has him sold to a band of passing Ishmaelites. The brothers dip Joseph's special coat in the blood of a goat and show it to their father, leading him to believe that his most beloved son was devoured by a wild beast.
Judah marries and has three children. The eldest, Er, dies young and childless, and his wife Tamar is given in levirate marriage to the second son, Onan. Onan sins by spilling his seed and he, too, meets an early death. Judah is reluctant to have his third son marry her. Determined to have a child from Judah's family, Tamar disguises herself as a prostitute and seduces Judah himself. Judah hears that his daughter-in-law has become pregnant and orders her executed for harlotry, but when Tamar produces some personal effects he left with her as a pledge for payment, he publicly admits that he is the father. Tamar gives birth to twin sons, Peretz (an ancestor of King David) and Zerach.
Joseph is taken to Egypt and sold to Potiphar, the minister in charge of Pharaoh's slaughterhouses. G-d blesses everything he does, and soon he is made overseer of all his master's property. Potiphar's wife desires the handsome and charismatic lad; when Joseph rejects her advances, she tells her husband that the Hebrew slave tried to force himself on her and has him thrown in prison. Joseph gains the trust and admiration of his jailers, who appoint him to a position of authority in the prison administration.
In prison, Joseph meets Pharaoh's chief butler and chief baker, both incarcerated for offending their royal master. Both have disturbing dreams, which Joseph interprets; in three days, he tells them, the butler will be released and the baker hanged. Joseph asks the butler to intercede on his behalf with Pharaoh. Joseph's predictions are fulfilled, but the butler forgets all about Joseph and does nothing for him.