The Israelites had been forbidden to claim any of the spoils of the city (Joshua 6:17-19 Joshua 6:17-19  And the city shall be accursed, even it, and all that are therein, to the LORD: only Rahab the harlot shall live, she and all that are with her in the house, because she hid the messengers that we sent.
 And you, in any wise keep yourselves from the accursed thing, lest you make yourselves accursed, when you take of the accursed thing, and make the camp of Israel a curse, and trouble it.
 But all the silver, and gold, and vessels of brass and iron, are consecrated to the LORD: they shall come into the treasury of the LORD.
American King James Version×). But one man thought he could be an exception. The Hebrew word translated "a disgraceful thing" in verse 15 "denotes a blatant and senseless disregard for God's will" (Nelson Study Bible, note on Joshua 7:15-16 Joshua 7:15-16  And it shall be, that he that is taken with the accursed thing shall be burnt with fire, he and all that he has: because he has transgressed the covenant of the LORD, and because he has worked folly in Israel.  So Joshua rose up early in the morning, and brought Israel by their tribes; and the tribe of Judah was taken:
American King James Version×). Sometimes one man's sin can adversely affect others who apparently had nothing to do with it. Thankfully, only 36 out of a few thousand men were lost (verses 3-5). Though tragic, the repercussions could have been much worse—as God declared the nation as a whole "doomed to destruction" (verse 12) until the sin was removed from its midst.
The King James Study Bible notes: "Achan is referred to as 'Achar, the troubler of Israel, who transgressed in the accursed thing' (1 Chronicles 2:7 1 Chronicles 2:7And the sons of Carmi; Achar, the troubler of Israel, who transgressed in the thing accursed.
American King James Version×). He was stoned to death for violating the 'ban' during the conquest of Jericho (v. 1). Achan stole 200 shekels of silver, a Babylonian garment, and a wedge of gold weighing 50 shekels and hid them in the earthen floor of his tent (v. 21). The sin of Achan was imputed to the whole nation (vv. 11, 12), and thus they were soundly defeated in the battle of Ai (vv. 4, 5). Israel learned the hard way that what one person does could affect the well-being of the whole nation. He was buried in the valley of Achor ('trouble,' v. 26). Achor is used in a figurative sense in Isaiah 65:10 Isaiah 65:10And Sharon shall be a fold of flocks, and the valley of Achor a place for the herds to lie down in, for my people that have sought me.
American King James Version×and Hosea 2:15 Hosea 2:15And I will give her her vineyards from there, and the valley of Achor for a door of hope: and she shall sing there, as in the days of her youth, and as in the day when she came up out of the land of Egypt.
American King James Version×to describe the messianic age or the time of restoration that would result for the nation of Israel only after they passed through trouble." Indeed, like in this example, the Great Tribulation will come upon Israel in the end time not because every single individual is in complete and total rebellion against God. Rather, because of the terrible sins of some—in fact, of many—that are not rooted out of Israel, suffering will come on all.
Ironically, if Achan had only waited until the very next battle with Ai, he would have been allowed to take spoil for himself (Joshua 8:2 Joshua 8:2And you shall do to Ai and her king as you did to Jericho and her king: only the spoil thereof, and the cattle thereof, shall you take for a prey to yourselves: lay you an ambush for the city behind it.
American King James Version×). But his greed got the better of him—and brought about his downfall.
Supplementary Reading:"Jericho: The Lesson of Not Coming Into Sin," The Good News expanded edition, March-April 1997, pp. E1-E3.