And Joshua sent men from Jericho to Ai, which is beside Beth-aven, on the east side of Beth-el, and spoke to them, saying, Go up and view the country. And the men went up and viewed Ai.
And he removed from thence to a mountain on the east of Beth-el, and pitched his tent, having Beth-el on the west, and Hai on the east: and there he erected an altar to the LORD, and called upon the name of the LORD.
Howl, O Heshbon, for Ai is laid waste: cry, ye daughters of Rabbah, gird you with sackcloth; lament, and run to and fro by the hedges; for their king shall go into captivity, and his priests and his princes together.
Though thou, Israel, playest the harlot, yet let not Judah offend; and come not ye to Gilgal, neither go ye up to Beth-aven, nor swear, The LORD liveth.
And their border on the north side was from Jordan; and the border went up to the side of Jericho on the north side, and went up through the mountains westward; and the limits of it were at the wilderness of Beth-aven.
And Joshua the son of Nun sent from Shittim two men to spy secretly, saying, Go, view the land, even Jericho. And they went, and came into the house of a harlot, named Rahab, and lodged there.
And they returned to Joshua, and said to him, Let not all the people go up; but let about two or three thousand men go up and smite Ai; and make not all the people to labor thither; for they are but few.
And the Philistines assembled to fight with Israel, thirty thousand chariots, and six thousand horsemen, and people as the sand which is on the sea shore in multitude: and they came up, and encamped in Michmash, eastward from Beth-aven.