Genesis 39:1-18 describes Joseph’s rise and fall as the slave of Potiphar, the captain of the guard in Egypt. He arrives in this situation after being sold by his own brothers (Genesis 37:26-28). The Lord continues to be with Joseph and to bless him. Potiphar promotes Joseph to the head manager of his household, even giving credit to Joseph’s God for all the success that follows. Potiphar’s wife is also impressed with Joseph, but in a less honorable way. She persistently tempts him to sleep with her. When Joseph refuses, she unfairly frames him for attempted rape.
Genesis 39:19-23 describes Joseph’s arrival in the Egyptian prison reserved for the king’s prisoners. Joseph’s once-trusting master has him jailed after the master’s wife falsely accuses Joseph of attempted rape. Despite the unfair imprisonment, God has not abandoned Joseph. The fact that Joseph isn’t immediately executed speaks well of both his reputation and the Lord’s protection. Even in prison, Joseph is blessed: the king’s jailer favors Joseph and quickly puts him in charge of nearly all of duties in the jail. Joseph continues to succeed in every circumstance he faces, under God’s provision.
Deuteronomy 31:6 (NIV) says Be strong and courageous. Do not be afraid or terrified because of them, for the Lord your God goes with you; he will never leave you nor forsake you.” These words certainly apply to Joseph during this time of his life. And they apply to God’s people throughout time. The divinely inspired writer of Hebrews would quote the last part of this verse at the end of Hebrews 13:5.