1808–14, fought by France against Great Britain, Portugal, Spanish regulars, and Spanish guerrillas in the Iberian Peninsula.
The conflict was precipitated when Portugal refused to comply with Napoleon's Continental System. By a secret convention reached at Fontainebleau (Oct., 1807) Spain agreed to support France against Portugal. A French army under Andoche Junot occupied (Nov., 1807) Portugal, and King John VI and his family fled to Brazil without resisting. Napoleon then began a series of maneuvers to secure Spain for France. On the pretext that they were reinforcements for Junot, large numbers of French troops entered Spain and seized Pamplona and Barcelona (Feb., 1808). On Mar. 23 French marshal Joachim Murat entered Madrid.
Meanwhile, a palace revolution (Mar. 19) had deposed King Charles IV and his favorite, Godoy, and had placed Ferdinand VII on the throne. However, Charles and Ferdinand were called to Bayonne by Napoleon, and coerced to abdicate (May 5–6) in favor of Napoleon's brother Joseph Bonaparte. A bloody uprising in Madrid (May 2)—immortalized in Francisco de Goya's paintings—was put down by Murat and on June 15 Joseph was proclaimed king of Spain.
The Spanish rose in revolt throughout the country. When the insurrectionists captured (July 23) a French force dispatched to seize Seville, King Joseph evacuated Madrid (Aug. 1) and withdrew beyond the Ebro. Another French force was repelled by José de Palafox in his heroic defense of Zaragoza (June–Aug.). In Portugal, where revolt had also broken out, a British expeditionary force under Arthur Wellesley (later duke of Wellington) landed in Aug., 1808, and defeated Junot at Vimeiro (Aug. 21). Cut off from Joseph's army, Junot negotiated a convention at Cintra (Aug. 30), surrendering Lisbon in return for repatriation of his troops by British ships.
With Sir John Moore as commander in chief, the British invaded Spain, thus beginning a long series of seesaw campaigns. Napoleon hastened to Spain, stormed Madrid (Dec. 3, 1808), had Marshal Lannes lay siege to Zaragoza, and ordered Marshal Soult to pursue Moore, who had retreated into Galicia. Soult was stalled long enough at A Coruña (Jan. 16, 1809) to permit the British to embark. Zaragoza, which Palafox had held for two months at a huge cost in lives, fell in Feb., 1809. In April, Wellesley arrived in Lisbon to take charge of the British and Portuguese forces there. He drove the French out of Portugal, invaded Spain, and with the help of a Spanish army defeated the French under Joseph at Talavera (July 27–28).
Driven back into Portugal by André Masséna at Bussaco (Sept., 1810), Wellesley retired behind a strong fortified line centered at Torres Vedras, which Masséna's forces attempted to penetrate (Oct.–Mar., 1811). Lacking supplies, Masséna retreated into Spain (Mar.–Apr., 1811); meanwhile Soult had marched north from Cádiz to join Masséna, but their junction was prevented by Wellesley and William Carr Beresford at Fuentes de Oñoro and at Albuera (May, 1811). Nevertheless, the French controlled all of Spain in 1811, with the exception of the numerous guerrilla bands operating out of the mountains, which continuously sapped French forces. There were atrocities on both sides.
Early in 1812 Wellesley attacked once more, and on July 22 he defeated the French under Marmont at Salamanca. He briefly occupied Madrid (Aug.–Oct., 1812), but retreated to Ciudad Rodrigo when the French, who had time to consolidate their armies, counterattacked from three directions. Placed in command of all the allied forces in the peninsula, Wellesley took the offensive in May, 1813, routed the French under Joseph Bonaparte and Marshal Jourdan at Vitoria (June 21), and pushed them back into France. In October Wellesley invaded France. He laid siege to Bayonne, heroically defended by Soult, and had reached Toulouse when, on Apr. 12, 1814, news of Napoleon's abdication arrived; the Peninsular War was ended.
The Peninsular War immeasurably raised Britain's military prestige and contributed heavily to Napoleon's downfall. The “guerrilla” warfare carried out by irregular Spanish forces added a new term to the military vocabulary and served as a model for future insurgencies. In Latin America the war served as detonator for the independence revolutions of the Spanish colonies.