Then Joshua the son of Nun sent two men as spies secretly from Shittim, saying, “Go, view the land, especially Jericho.” So they went and came into the house of a harlot whose name was Rahab, and lodged there. It was told the king of Jericho, saying, “Behold, men from the sons of Israel have come here tonight to search out the land.” And the king of Jericho sent word to Rahab, saying, “Bring out the men who have come to you, who have entered your house, for they have come to search out all the land.” But the woman had taken the two men and hidden them, and she said, “Yes, the men came to me, but I did not know where they were from. It came about when it was time to shut the gate at dark, that the men went out; I do not know where the men went. Pursue them quickly, for you will overtake them.” But she had brought them up to the roof and hidden them in the stalks of flax which she had laid in order on the roof. So the men pursued them on the road to the Jordan to the fords; and as soon as those who were pursuing them had gone out, they shut the gate.
Now before they lay down, she came up to them on the roof, and said to the men, “I know that the LORD has given you the land, and that the terror of you has fallen on us, and that all the inhabitants of the land have melted away before you. For we have heard how the LORD dried up the water of the Red Sea before you when you came out of Egypt, and what you did to the two kings of the Amorites who were beyond the Jordan, to Sihon and Og, whom you utterly destroyed. When we heard it, our hearts melted and no courage remained in any man any longer because of you; for the LORD your God, He is God in heaven above and on earth beneath. Now therefore, please swear to me by the LORD, since I have dealt kindly with you, that you also will deal kindly with my father’s household, and give me a pledge of truth, and spare my father and my mother and my brothers and my sisters, with all who belong to them, and deliver our lives from death.” So the men said to her, “Our life for yours if you do not tell this business of ours; and it shall come about when the LORD gives us the land that we will deal kindly and faithfully with you.”