Once again, the main outline is from the Open Bible, slightly edited.
Sin with the Moabites, v.1-5
Baal worship and sensuality
Israel abode in Shittim, also called Abel-shittim in Num 33:49. The name may describe acacia trees. All that we know is that it was a place on the East of Jordan.
The people began to commit sexual sins with the women of Moab in that area (v.1). Those women invited the people to the sacrifices of their gods, and the people bowed to their gods (v.2). “Prostitution was part of that worship.” Ryrie They joined themselves in worship of Baalpeor, one of the Baal gods (v.3). This was no accident. The Moabites and Midianites did it intentionally at the counsel of Balaam (Nu 31:16; Rev 2:14). These two nations were working together (c.f., Nu 22:4, 7).
Their sexual sins led them to spiritual sins. This is just as true today. Sexual sins always harm one’s spiritual communion with God. Satan is such a deceiver!
God’s judgment
This, of course, roused the Lord’s anger against Israel (v.3). God ordered Moses to execute the heads (i.e., leaders) of the people, against the sun (i.e., publicly, before sundown).
Moses commanded the judges (likely his 70 helpers who had his spirit) to slay the men under his jurisdiction who had joined with Baalpeor (v.5).
Phinehas the Priest Intervenes, v. 6-15
If these verses are in chronological order, right after or the day after the judges killed the Israelite men who had been immoral, an Israelite man boldly brought in one of the immoral Midianitish women into the camp, and into his tent, in the sight of Moses and others who were weeping over these sins and God’s judgment (v.6).
David Guzik points out that, “In this chapter, the women and their people are sometimes described as Midianites and sometimes as Moabites. This is because the Midianites were a nomadic group, and at this time, were in high numbers among the Moabites.”
Phinehas, the grandson of Aaron, took a javelin or spear and went into that man’s tent and speared them both at the same time. By this judgment against these sexual sins, the plague was stopped. God had ordered such execution and Phinehas, the priest, carried it out. This man’s sin stood out because he knew of God’s anger and of the slaughter of the offenders and he defied all that by his bold actions.
A total of 24,000 died in this incident (v.9). In 1 Corinthians 10:8, we read that 23,000 fell in one day. Evidently, 1,000 more died after the initial day of slaughter in connection with the couple killed by Phinehas.
Because of his hatred for sin and his zeal to defend the Lord’s holiness, God gave Phinehas a special blessing (v.10-13). God gave him a covenant of peace. His actions made an atonement for Israel (v.13).
The name of the sinning Israelite man was Zimri and the Midianitish woman was Cozbi (v.14-15).
Israel must fight against Moab, v.16-18
God commanded Moses to vex the Midianites and to smite them (v.16-17). The word “vex” can mean to bind, to distress, to besiege, or to oppress. God ordered this because the Midianites had vexed Israel. To “smite” is to wound.
Principles for Us Today
Zimri’s shameless bold immorality reminds us of the immoral plague of our day. Many people, including many professing Christians, see nothing wrong with living with a partner outside of marriage. God clearly condemns that (Rom 13:13; 1Th 4:3; Heb 13:4).
Sexual sins are a great curse to God’s people. This has never been truer than today. Do not underestimate this great danger. Innumerable Christians have lost their fellowship with God because of unconfessed and unforsaken sexual sins. We must flee this like a plague. (2 Timothy 2:22) “Flee also youthful lusts: but follow righteousness, faith, charity, peace, with them that call on the Lord out of a pure heart.“
Sin grieves God and He cannot overlook it.
While we are to love the sinner, but hate his sin, we must strongly vex or oppose every form of sexual sin. Clearly warn our children. Guard our minds. Filter our media.