Tamar was told, “Listen, your father-in-law is going up to Timnah to shear his sheep.” So she removed her widow’s clothes and covered herself with a veil, and wrapped herself up [in disguise], and sat in the gateway of Enaim, which is on the road to Timnah; for she saw that Shelah had grown up, and she had not been given to him as a wife [as Judah had promised]. When Judah saw her, he thought she was a [temple] prostitute, for she had covered her face [as such women did]. He turned to her by the road, and said, “Please come, let me lie with you”; for he did not know that she was his daughter-in-law. And she said, “What will you give me, that you may lie with me?” He answered, “I will send you a young goat from the flock.” And she said, “Will you give me a pledge [as a deposit] until you send it?” He said, “What pledge shall I give you?” She said, “Your seal and your cord, and the staff that is in your hand.” So he gave them to her and was intimate with her, and she conceived by him. Then she got up and left, and removed her veil and put on her widow’s clothing.
When Judah sent the young goat by his friend the Adullamite, to get his pledge [back] from the woman, he was unable to find her. He asked the men of that place, “Where is the temple prostitute who was by the roadside at Enaim?” They said, “There was no prostitute here.” So he returned to Judah, and said, “I cannot find her; also the local men said, ‘There was no prostitute around here.’ ” Then Judah said, “Let her keep the things (pledge articles) for herself, otherwise we will be a laughingstock [searching everywhere for her]. After all, I sent this young goat, but you did not find her.”
About three months later Judah was told, “Tamar your daughter-in-law has played the [role of a] prostitute, and she is with child because of her immorality.” So Judah said, “Bring her out and let her be burned [to death as punishment]!” While she was being brought out, she [took the things Judah had given her and] sent [them along with a message] to her father-in-law, saying, “I am with child by the man to whom these articles belong.” And she added, “Please examine [them carefully] and see [clearly] to whom these things belong, the seal and the cord and staff.” Judah recognized the articles, and said, “She has been more righteous [in this matter] than I, because I did not give her to my son Shelah [as I had promised].” And Judah did not have [intimate] relations with her again.
Now when the time came for her to give birth, there were twins in her womb. And when she was in labor, one [baby] put out his hand, and the midwife took his hand and tied a scarlet thread on it, saying, “This one was born first.” But he pulled back his hand, and his brother was born first. And she said, “What a breach you have made for yourself [to be the firstborn]!” So he was named Perez (breach, break forth). [Matt 1:3] Afterward his brother who had the scarlet [thread] on his hand was born and was named Zerah (brightness).