Yehoshua sent spies to scout out the city of Ai, thinking it would be easy to conquer with only 3,000 soldiers. However, the attack failed, and they did not know why until Achan was killed for taking forbidden items from a previous battle. Yehoshua then came up with a new plan where his small army would pretend to flee from Ai's king and army, luring them away from the undefended city so that Yehoshua's men could return, set fire to Ai, and conquer it.