In the struggle for the independence of Spanish America, the Reconquista refers to the period of Colombian and Chilean history, following the defeat of Napoleon in 1814, during which royalist armies were able to gain the upper hand in the Spanish American wars of independence. The term used in the past century by some Colombian and Chilean historians makes an analogy to the medieval Reconquista, in which Christian forces retook the Iberian Peninsula from the Caliphate.