In 1195, after the treaty with the Almohads was broken, he came to the defence of Alarcos on the river Guadiana, then the principal Castilian town in the region. At the subsequent Battle of Alarcos, he was roundly defeated by the caliph Abu Yusuf Yaqub al-Mansur. The reoccupation of the surrounding territory by the Almohads was quickly commenced with Calatrava falling first. For the next seventeen years, the frontier between Moor and Castilian was fixed in the hill country just outside Toledo.