And the LORD said to Joshua, "Do not fear or be dismayed; take all the fighting men with you, and arise, go up to Ai; see, I have given into your hand the king of Ai, and his people, his city, and his land;
and you shall do to Ai and its king as you did to Jericho and its king; only its spoil and its cattle you shall take as booty for yourselves; lay an ambush against the city, behind it."
And he commanded them, "Behold, you shall lie in ambush against the city, behind it; do not go very far from the city, but hold yourselves all in readiness;
and they will come out after us, till we have drawn them away from the city; for they will say, `They are fleeing from us, as before.' So we will flee from them;
So Joshua sent them forth; and they went to the place of ambush, and lay between Bethel and Ai, to the west of Ai; but Joshua spent that night among the people.
And all the fighting men who were with him went up, and drew near before the city, and encamped on the north side of Ai, with a ravine between them and Ai.
So they stationed the forces, the main encampment which was north of the city and its rear guard west of the city. But Joshua spent that night in the valley.
And when the king of Ai saw this he and all his people, the men of the city, made haste and went out early to the descent toward the Arabah to meet Israel in battle; but he did not know that there was an ambush against him behind the city.
Then the LORD said to Joshua, "Stretch out the javelin that is in your hand toward Ai; for I will give it into your hand." And Joshua stretched out the javelin that was in his hand toward the city.
And the ambush rose quickly out of their place, and as soon as he had stretched out his hand, they ran and entered the city and took it; and they made haste to set the city on fire.
So when the men of Ai looked back, behold, the smoke of the city went up to heaven; and they had no power to flee this way or that, for the people that fled to the wilderness turned back upon the pursuers.
And when Joshua and all Israel saw that the ambush had taken the city, and that the smoke of the city went up, then they turned back and smote the men of Ai.
And the others came forth from the city against them; so they were in the midst of Israel, some on this side, and some on that side; and Israel smote them, until there was left none that survived or escaped.
When Israel had finished slaughtering all the inhabitants of Ai in the open wilderness where they pursued them and all of them to the very last had fallen by the edge of the sword, all Israel returned to Ai, and smote it with the edge of the sword.
And he hanged the king of Ai on a tree until evening; and at the going down of the sun Joshua commanded, and they took his body down from the tree, and cast it at the entrance of the gate of the city, and raised over it a great heap of stones, which stands there to this day.
as Moses the servant of the LORD had commanded the people of Israel, as it is written in the book of the law of Moses, "an altar of unhewn stones, upon which no man has lifted an iron tool"; and they offered on it burnt offerings to the LORD, and sacrificed peace offerings.
And all Israel, sojourner as well as homeborn, with their elders and officers and their judges, stood on opposite sides of the ark before the Levitical priests who carried the ark of the covenant of the LORD, half of them in front of Mount Gerizim and half of them in front of Mount Ebal, as Moses the servant of the LORD had commanded at the first, that they should bless the people of Israel.
There was not a word of all that Moses commanded which Joshua did not read before all the assembly of Israel, and the women, and the little ones, and the sojourners who lived among them.