1. The LORD said to Joshua, "Take all the soldiers with you and go on up to Ai. Don't be afraid or discouraged. I will give you victory over the king of Ai; his people, city, and land will be yours.
2. You are to do to Ai and its king what you did to Jericho and its king, but this time you may keep its goods and livestock for yourselves. Prepare to attack the city by surprise from the rear."
3. So Joshua got ready to go to Ai with all his soldiers. He picked out thirty thousand of his best troops and sent them out at night
4. with these orders: "Hide on the other side of the city, but not too far away from it; be ready to attack.
5. My men and I will approach the city. When the men of Ai come out against us, we will turn and run, just as we did the first time.
6. They will pursue us until we have led them away from the city. They will think that we are running from them, as we did before.
7. Then you will come out of hiding and capture the city. The LORD your God will give it to you.
8. After you have taken the city, set it on fire, just as the LORD has commanded. These are your orders."
9. So Joshua sent them out, and they went to their hiding place and waited there, west of Ai, between Ai and Bethel. Joshua spent the night in camp.
10. Early in the morning Joshua got up and called the soldiers together. Then he and the leaders of Israel led them to Ai.
11. The soldiers with him went toward the main entrance to the city and set up camp on the north side, with a valley between themselves and Ai.
12. He took about five thousand men and put them in hiding west of the city, between Ai and Bethel.
13. The soldiers were arranged for battle with the main camp north of the city and the rest of the men to the west. Joshua spent the night in the valley.
14. When the king of Ai saw Joshua's men, he acted quickly. He and all his men went out toward the Jordan Valley to fight the Israelites at the same place as before, not knowing that he was about to be attacked from the rear.
15. Joshua and his men pretended that they were retreating, and ran away toward the barren country.
16. All the men in the city had been called together to go after them, and as they pursued Joshua, they kept getting farther away from the city.
17. Every man in Ai went after the Israelites, and the city was left wide open, with no one to defend it.
18. Then the LORD said to Joshua, "Point your spear at Ai; I am giving it to you." Joshua did as he was told,
19. and as soon as he lifted his hand, the men who had been hiding got up quickly, ran into the city and captured it. They immediately set the city on fire.
20. When the men of Ai looked back, they saw the smoke rising to the sky. There was no way for them to escape, because the Israelites who had run toward the barren country now turned around to attack them.
21. When Joshua and his men saw that the others had taken the city and that it was on fire, they turned around and began killing the men of Ai.
22. The Israelites in the city now came down to join the battle. So the men of Ai found themselves completely surrounded by Israelites, and they were all killed. No one got away, and no one lived through it
23. except the king of Ai. He was captured and taken to Joshua.
24. The Israelites killed every one of the enemy in the barren country where they had chased them. Then they went back to Ai and killed everyone there.
25. Joshua kept his spear pointed at Ai and did not put it down until every person there had been killed. The whole population of Ai was killed that day---twelve thousand men and women.
26. {cf15I (SEE 8:25)}
27. The Israelites kept for themselves the livestock and goods captured in the city, as the LORD had told Joshua.
28. Joshua burned Ai and left it in ruins. It is still like that today.
29. He hanged the king of Ai from a tree and left his body there until evening. At sundown Joshua gave orders for the body to be removed, and it was thrown down at the entrance to the city gate. They covered it with a huge pile of stones, which is still there today.
30. Then Joshua built on Mount Ebal an altar to the LORD, the God of Israel.
31. He made it according to the instructions that Moses, the LORD's servant, had given the Israelites, as it says in the Law of Moses: "an altar made of stones which have not been cut with iron tools." On it they offered burnt sacrifices to the LORD, and they also presented their fellowship offerings.
32. There, with the Israelites looking on, Joshua made on the stones a copy of the Law which Moses had written.
33. The Israelites, with their leaders, officers, and judges, as well as the foreigners among them, stood on two sides of the LORD's Covenant Box, facing the levitical priests who carried it. Half of the people stood with their backs to Mount Gerizim and the other half with their backs to Mount Ebal. The LORD's servant Moses had commanded them to do this when the time came for them to receive the blessing.
34. Joshua then read aloud the whole Law, including the blessings and the curses, just as they are written in the book of the Law.
35. Every one of the commandments of Moses was read by Joshua to the whole gathering, which included women and children, as well as the foreigners living among them.