Achan's Sin Affects Israel (Joshua 7)
The Israelites had taken Jericho. The Lord had commanded them to kill everyone in the city and give all the spoils to him. They had done this, killing everyone except for Rahab and her family and gathering all the riches together to give to the Lord. One of the Israelites was tempted to keep some of the spoils, though. His name was Achan. He had found, while going through the city, a precious robe, some silver coins and a wedge of gold. Hiding them in his clothing, he went back to his tent and buried them, thinking no one had seen him.
Israel was triumphant. They had destroyed Jericho and were now about to attack a smaller town, Ai. Joshua's spies had said this task would only take a few thousand men, so he had sent his army out to conquer. Amazingly, his men were defeated. They lost about 36 men and were chased away by the locals. Joshua couldn't understand it, and turned to the Lord to ask why he had deserted him. God told Joshua that someone had broken his commandment; that they had taken some of the spoil from Jericho for themselves and they must be killed for it.
The next morning, Joshua got the twelve tribes to march past him. The Lord pointed out the tribe of Judah. He made the families of Judah march before him and the Lord pointed out the family of the Zarhites. Then he narrowed it down to the family of Zabdi, and finally Achan himself. Achan confessed to his sin and the treasure was dug up from his tent. Achan, his family and all his possessions were taken away. The people were stoned to death and everything burned.
Ai Taken (Joshua 8)
Once Achan had been punished, God told Joshua that he would give him Ai, and this time they could take the spoil for themselves. Joshua sent his army out to attract out the people of Ai. All their men came out and chased Israel. But Joshua had set up an ambush. His men set fire to the city and burned it down. Both sets of men then attacked the Ai soldiers and killed them all.
12,000 people were killed that day in Ai, and the city was left in destruction.