A prostitute or innkeeper in Jericho who shelters and assists the two spies sent by Yehoshua prior to the nation's conquest of Canaan. Rahav hides the two men from soldiers of Jericho who are searching for them. In return for this deed, Rahav requests and receives assurances that she and her family will be spared when Israel attacks. (Courtesy of Rabbi Jonathan Mishkin)

When the king asks her to give up the spies, she counters the act of a prostitute - giving up one's values for money - with values of hessed and dedication for the greater good. Read more here

Additional articles on Rahav:

Rachav and the Spies

The Drama of Rachav