1 While Israel was living at Shittim, the people began to commit sexual immorality with the women of Moab,
2 who invited the people to the sacrifices to their gods. The people ate and bowed down to their gods.
3 So Israel attached itself to Baal of Peor, and the LORD's anger burned against Israel.
4 The LORD said to Moses, "Take all the leaders of the people and hang them before the LORD in broad daylight, so that the LORD's burning anger may turn away from Israel."
5 So Moses said to Israel's judges, "Each of you must kill those of his men who have attached themselves to Baal of Peor."
6 Just then one of the children of Israel came and brought a Midianite woman to his relatives, before the eyes of Moses and the whole congregation of the children of Israel, while they were weeping at the entrance of the tent of meeting.
7 When Phinehas son of Eleazar, son of Aaron the priest, saw this, he got up from the congregation, took a spear in his hand,
8 followed the man of Israel into the chamber, and drove the spear through both of them, through the man of Israel and through the woman's belly. Then the plague on the children of Israel was halted.
9 Twenty-four thousand had died in the plague.
10 The LORD spoke to Moses, saying,
11 "Phinehas son of Eleazar, son of Aaron the priest, has turned my wrath away from the children of Israel by being zealous among them with my zeal, so that I did not wipe out the children of Israel in my zeal.
12 So tell him that I am granting him my covenant of peace.
13 It will be for him and his descendants after him a covenant of lasting priesthood, because he was zealous for his God and made atonement for the children of Israel."
14 The name of the man of Israel who was struck down with the Midianite woman was Zimri son of Salu, chief of a father's house of the Simeonites.
15 The name of the Midianite woman who was struck down was Cozbi daughter of Zur, who was the head of the clans of a father's house in Midian.
16 The LORD spoke to Moses, saying,
17 "Treat the Midianites as enemies and strike them,
18 because they treated you as enemies by the tricks they used to deceive you in the matter of Peor and in the matter of their sister Cozbi, the daughter of a Midianite chief, who was struck down on the day of the plague that came because of Peor."