Join War on the Rocks and gain access to content trusted by policymakers, military leaders, and strategic thinkers worldwide.
Early on the morning of July 16, 1808, Captain-General Francisco Javier Castaños of the Army of Andalusia launched a surprise attack against the divided forces of Emperor Napoleon Bonaparte’s Army of the Gironde. After three grueling days of combat, French Gen. Pierre Dupont requested a truce and opened negotiations outside the village of Bailén. Beginning on July 22, 17,000 French soldiers — encircled, exhausted, and out of supplies — surrendered their arms, their flags, and three imperial eagles to the Spanish — men who had first shouldered a musket scarcely eight weeks earlier. The capitulation at Bailén may not express the finality of a “world turned upside down,” yet it represented something equally impressive: the turning of the tide against Napoleon’s inexorable push to establish and enforce a new continental political order.
Although tactically pedestrian, Bailén offers military aficionados dramatic lessons in true Spanish fashion. First, even grandmasters in the art of war may instigate foolhardy conflicts. Second, their overconfidence may lead them to assign impossible tasks to untested subordinates when failure could be catastrophic to their cause. Third, the demands of autonomous command placed upon a bold tactician frequently results in operational paralysis. Most importantly, Bailén cautions all powers about the chaos unleashed when legitimate governments — even quite unpopular ones — are overthrown without a strong alternative quickly and securely establishing itself. When political authority devolves into local power struggles, military professionals must determine whom to obey and why. The longer the chaos, the more difficult it becomes for a military — especially one led by patriotic officers — to remain bound by traditional limits.
By March 1808, the decades-long drama encompassing the Spanish house of Bourbon had become worthy of a telenovela, starting with King Carlos IV’s complacency about his queen’s openly adulterous relationship with their chief minister, Manuel de Godoy. The disgusted Crown Prince Ferdinand conspired first against Godoy and, when foiled, turned against his cuckolded father, also unsuccessfully. Finally, protestors spontaneously invaded the royal palace, defenestrated the queen’s lover, and forced Carlos’s momentary abdication. Well might one wonder why Napoleon, subduer of Austria and conqueror of Prussia, would bother with such degeneracy at all. Scholars have suggested a number of factors, ranging from an inveterate hatred of the house of Bourbon, to a mistaken belief that Spain’s treasury was far richer than presumed, to yet another manifestation of the emperor’s growing political impatience. As early as November 1807, under the guise of reinforcing Division-General Jean-Andoche Junot’s campaign against a recalcitrant Portugal, 90,000 French soldiers began crossing the Pyrenees, occupying key fortresses and cities in Navarre, Castile, and Catalonia through a mix of bravado and deception. Carlos IV’s impotent response persuaded Bonaparte to lure king and heir to Bayonne in April, force their abdications, and install his reluctant brother Joseph on the throne. Never before had Napoleon attempted something so politically audacious: The coup shocked heads of state throughout Europe. Popular discontent likewise increased, but the kingdom — effectively leaderless — appeared resigned to its fate. No one, certainly not Marshal Joachim Murat, Napoleon’s brother-in-law and regional commander, expected things to change.
Yet Murat’s breezy confidence was abruptly shaken on May 2 when a carriage, arriving in Madrid to remove the remaining Bourbons, sparked a protest that quickly turned violent. Murat brought artillery as well as Mameluke cavalry into the streets to restore order, killing hundreds. French reprisals began that evening and continued over several days. Yet the reprisals failed to intimidate the masses and resistance spread over the next three weeks. Previous regional antagonism or indifference to Madrid transformed into a fierce desire to emulate its defiance against the invaders. Spain and France had endured centuries of bad blood. The French Revolution’s anti-Catholic aspects, Spain’s humbling at the hands of the Republic in 1795, and the subsequent Second Treaty of San Ildefonso that cemented its inferior position under the guise of an alliance further sharpened feelings of animosity. Napoleon’s contemptuous treatment of Spain’s royal family was simply the final insult.
The three most prominent centers of resistance — Asturias in the northwest, Valencia in the east, and Andalusia in the south — established provisional juntas, seized military stockpiles, and called for volunteers, while negotiating with prominent generals to gauge their loyalty. With Murat falling ill with a fever in late May and Joseph still not formally installed as king or even in Spain, Napoleon was thrown on his back foot.
Determined to nip the rebellion in the bud, the emperor dispatched flying columns of 15,000 men each, while keeping substantial reserves in the capital to secure lines of communication. The stalwart Marshal Jean-Baptiste Bessières would seize Asturias and the competent Marshal Bon-Adrien Jeannot de Moncey would move eastward to reclaim Valencia. Napoleon directed his most promising subordinate, Divisional-General Pierre Dupont, to push through Andalusia and secure the seaport of Cádiz, freeing the remnants of France’s fleet that had survived Trafalgar and now lay blockaded by British Vice Adm. Cuthbert Collingwood. Emphasizing speed despite insufficient mounts in country, Napoleon insisted to the trio — each exercising his first autonomous command — that there should be no retrograde movement, believing that such typically prudential action would on this occasion hearten the population and incite broader resistance.
Despite the presumption of ongoing Spanish pusillanimity, the stakes of the campaign were high. Successful execution would smooth Joseph’s accession, demonstrating the new regime’s strength and resolve. A subdued Spain would also secure Napoleon’s southwestern flank, providing the emperor with an unparalleled freedom of maneuver against Austria or Russia, even conceivably against Gibraltar. If — against all odds — the impoverished Spanish regulars and their untrained volunteer compatriots were able to defeat any one of Napoleon’s columns, it would provide breathing room for the juntas to continue organizing resistance, possibly gather together into a national body, and even seek foreign assistance. Already Asturias, with nothing to lose, had sent emissaries to Britain on May 30. It was a long shot that a historic enemy who only recently had assaulted Spain’s American colonies would consider abetting a cabal of uncertain legitimacy or strength, yet stranger things had happened before in European diplomacy.
In giving Dupont the most audacious objective, the farthest distance to cover, and the greatest territory to secure, Napoleon had chosen an officer with a remarkable blend of loyalty, bravery, and ambition, combining a seasoned reputation for doughty fighting with a willingness to carry out the most difficult tasks. Contemporaries and historians alike have presumed that a successful campaign would earn Dupont a title of nobility and a marshal’s baton.
The indifferent quality of Dupont’s corps evinced Napoleon’s brash self-assuredness. His men were mostly conscripts, raised in the winter of 1806 to 1807, who had been garrisoning the Atlantic coast. These were supplemented by regional levies, officered by newly minted subalterns or recent retirees. Among his entire force, the only veterans Dupont could rely on were two battalions of the Marins de la Garde — naval infantry of the Imperial Guard comprising 1,700 men — and nearly 1,000 Swiss mercenaries, recently persuaded to transfer their allegiance.
On the Spanish side, things were even worse. Army morale had been low for decades, leading to undermanned regiments and a dearth of qualified officers. Culturally, there was a high-spiritedness among the rank and file that made discipline a challenge. Compounding this was the officers’ inability or unwillingness to earn the troops’ respect. The new juntas were typically led by notables inordinately proud of their local patrias. The majority evinced great mistrust of one another and any general whom Godoy had promoted. After weeks of contention, Seville’s junta unilaterally settled upon 50-year-old Lt. Gen. Francisco Javier Castaños to halt Dupont’s advance south by any means necessary. Granted his first captaincy in 1768 at age 10, the madrileño had experienced innumerable promotions but no combat until 1793. He seemed a safe choice, competent and without Caesarian impulses.
Dupont departed Toledo on May 24 with 13,000 men: one division with its artillery complement and some cavalry. Speed was essential for several reasons. There was only one good road south across La Mancha and one functional pass over the Sierra Morena into Andalusia, making Dupont’s advance extremely obvious and therefore extremely vulnerable. Additionally, Spain’s barren high plateau created severe logistical challenges for armies attempting to live off the land. A sober commander attempting a southern campaign would do well to remember: “Spain is a country where small armies are defeated and large armies starve.” Still, the lack of any opposition even in the mountains bolstered Dupont’s confidence so much that he refused to secure either the pass or the Madrid road. By June 5, his men occupied Andújar, a critical road junction on the Andalusian plains. Here he received word of Castaños’ gathering force and of surprising defiance from nearby Córdoba.
Assuming correctly that he had weeks before Castaños was ready to move, Dupont threw all his energies into seizing Córdoba by a coup de main, for his small column did not have enough artillery for a full-blown siege. Within 48 hours, his men had swept aside the locals’ ephemeral resistance and lay encamped outside its walls. Miscommunication during surrender negotiations the following day gave the general a dubious excuse to storm and sack the city. As his men enjoyed their spoils, a confident Dupont wrote Madrid for reinforcements to press his advance.
Yet Dupont was grossly mistaken in thinking that vigorous plundering would cow the Andalusians. His dishonorable conduct, exacerbated by the sacrilegious plundering of Córdoba’s churches, generated irregular but violent responses. As the days passed, messengers to the French camp brought not word of expected assistance from Madrid but tales of horror previously unknown to any imperial army. Dupont’s men found themselves suddenly and gruesomely assaulted by a new type of warrior, the guerrilla. Whether fighting a new Reconquista or merely taking advantage of the times to engage in banditry without consequence, the guerrillas’ unpredictable and intense violence would have a crippling effect on Dupont’s decision-making throughout the remainder of the campaign.
It slowly dawned on the French commander that his whole corps would not suffice to take Seville, let alone the more distant Cádiz. Moreover, he began to doubt his capacity to control any area his men did not physically occupy. Andalusia’s lone road to Madrid was drawing ever-increasing numbers of guerrillas to it like sharks to blood. Unnerved, Dupont withdrew to Andújar and dithered for over a month. Neither accounts of Adm. François de Rosily-Mesros’ surrender of the fleet in Cádiz to its junta on June 14 nor the arrival on June 27 of reinforcements under the capable Gen. Dominique Vedel that swelled his force to about 20,000 stirred him to action.
Meanwhile Castaños had organized about 34,000 men into four divisions of varying quality. Given the volume of inexperienced volunteers, Castaños believed it both morally beneficial and politically expedient to advance. Yet the Army of Andalusia — hampered by the same logistical problems as its foe — moved slowly, only reaching the Guadalquivir River by the second week in July.
Rather than test his enemy’s mettle and curry fortune’s favor by hazarding a battle while his relatively seasoned men were still confident, Dupont passively erected a defensive perimeter 15 miles along the northern bank of the river, placing himself in the west at Andújar and Vedel on his eastern flank at Bailén, a village strategically located in the foothills of the Sierra Morena. Critically, Dupont refused to have his cavalry patrol the river’s southern bank, limiting his awareness of Castaños’ future movements.
At a council of war on July 11, Castaños proposed pinning Dupont at Andújar with 12,000 of his less-reliable units while sending his larger and best divisions under Field Marshal Theodor von Reding upstream to force a crossing at Mengibar, turn Dupont’s left, and fall on Bailén. Castaños also enlisted a flying brigade of relatively controllable guerrillas to push northeast along the foothills, channeling their violence to disrupt Dupont’s right flank and rear. The plan was ambitious and demanded a lot of raw recruits. If the proven Dupont and Vedel executed a proper defense along interior lines and aggressively manned their fortified river crossings, the Spanish risked slaughter and disaster. But, as one scholar ably put it, “in this curious campaign the probable never happened, and everything went in the most unforeseen fashion.”

At first, things managed to go Dupont’s way. French dragoons easily repulsed von Reding’s initial crossings at Mengibar on July 14 and 15, causing Dupont to believe that Castaños represented the real threat. That night, he ordered Vedel to join him in haste. Early in the morning of July 16, however, Dupont — hearing a rumor that von Reding’s division had actually forced the Guadalquivir and seized the road to Madrid — immediately countermanded his previous order. The frustrated Vedel — without cavalry to confirm the report and desperate not to be cut off — sent his men on forced marches, pushing beyond Bailén into the mountains, only to find by the evening of July 17 that a 30-mile gap had now opened between his division and Dupont and — critically — that there were no Spanish troops in the mountains.
On the morning of July 18, von Reding’s force of 17,000 crossed the now undefended Guadalquivir and blithely occupied the hills to the west of Bailén, effectively splitting the French position. That night, the now frantic Dupont — fully aware of the trap he was in — pushed his outnumbered men east down the single road that was their last chance to escape. Still thinking Bailén secured, the French moved without a cavalry screen. Before daybreak on July 19, Dupont’s lead division under Brig. Gen. Theodore Chabert unexpectedly broke upon the Spanish pickets, formed in double semicircular lines on the hills and supported in the center by a 16-gun battery.
Riding to the sound of the guns, Dupont resolved to assail the enemy as soon as enough regiments moved around his bloated baggage train and his modest cavalry arrived. Three subsequent piecemeal assaults against the northern and southern hillcrests were thrown back by the timely arrival of Spanish reserves and concentrated artillery fire, as temperatures rose well above 100 degrees. When his last reserve — the Marins de la Garde — arrived on the field, Dupont formed them into a wedge directed against the massed batteries of the Spanish center, placing himself and his staff at their head. His gallant assault reached the very muzzles of the cannon, only to be driven back, defeated. As von Reding led the Army of Andalusia’s counterattack, Dupont’s Swiss units immediately revised their recently enforced allegiance to Napoleon, deserting en masse to their compatriot.
Utterly exhausted, drained by heat and thirst, Dupont’s men could take no more. At 2 p.m., Dupont requested a parley with Castaños, just as Vedel’s countermarching division arrived on the field. Over 2,000 Frenchmen lay dead or wounded on the field of battle. The Spanish had suffered fewer than 1,000 casualties. More significant was Dupont’s willingness to surrender all French survivors, including Vedel’s unengaged force — 17,000 men in all. Both sides were flabbergasted. One Spanish officer wrote afterward: “it was all a prodigy which did not seem to be the work of men.” Vedel refused to credit reports of surrender. Even after receiving a direct order signed by Dupont to stand down, he would not admit defeat for several days. Dupont compounded the ignominy of the moment by agreeing to surrender all French forces south of La Mancha, receiving in return only a guarantee of safe passage to an Andalusian port for transportation home.
However, neither the juntas nor the Spanish citizenry nor the British Royal Navy cared to treat the French so honorably. While Dupont, Vedel, and their staffs would eventually be evacuated from Cádiz to Marseilles — there to be imprisoned on Napoleon’s orders, the rank and file — interned on a desolate island in the Balearics — suffered greatly. Scarcely one in three was alive to be released in 1814.
Dupont’s surrender, rendering a third of Napoleon’s army hors de combat, sent shock waves through Spain. This debacle — coming on the heels of Moncey’s setback in Valencia, false rumors of Bessières’ defeat, and increasing evidence of open hostility in his own capital — was too much for Joseph. The three-week monarch, his court, and 20,000 soldiers fled Madrid, not stopping until they had crossed the Ebro, 220 miles away.
Castaños’ victory breathed new life into Austrian, Prussian, and even papal opposition movements to Napoleon. Most critically, Britain’s Tory government voted to intervene on the peninsula. Although army superiors undercut Sir Arthur Wellesley’s dramatic victories at Roliça and Vimeiro in Portugal that forced Junot’s surrender, a second invasion force under Sir David Baird landed at La Coruña that autumn to continue the liberation of Spain.
Napoleon, meanwhile, would spend the next two months amassing a 300,000-man juggernaut — nearly 60 percent of his entire military — and constructing a master plan for revenge. Crossing the Pyrenees in early November, he swept across Spain in a matter of weeks, overwhelming every army sent against him and forcing the British to evacuate. Despite these impressive successes, the emperor failed to grasp — or grasping, failed to confront — the reality that 1808 had unleashed a revolutionary conflict. Impossible to resolve on the battlefield, this fight would compromise his effectiveness on fields farther east over the next five years. Loath to acknowledge it, Napoleon would need to rely more than ever on diplomatic rather than military solutions, an approach that became increasingly intractable. The pain brought about as a result of his “Spanish ulcer” would remain with Bonaparte to his dying days on St. Helena.
For the victors, Bailén’s success, accompanied by ongoing resistance in places like Zaragoza and Girona, revealed that Spain still had one national institution — the military — that could stand competently against the invader. Its determined spirit and volunteer composition likewise made these armies beacons for national hope. Sadly, the hope that future tactical victories would stimulate a more cohesive resistance throughout the country proved ephemeral.
Juntas that effectively mobilized local defensive forces were logistically incapable of supplying sustained operations and temperamentally incapable of ceding authority to any other body. Guerrilla leaders — even those with noble intentions — likewise demonstrated a reluctance to engage cooperatively, let alone in a subordinate position. Instead of consolidating and capitalizing on Joseph’s dismay, they frittered away the following months squabbling for preeminence. The lack of historical precedent for empowering either a legislative assembly or a general-in-chief apart from royal initiative utterly paralyzed political and military authorities. Eventually, enough regions agreed to form a Supreme Junta, yet — riven by factions and facing rebellion in Latin America — its members could neither agree upon articles of governance nor even designate a commander-in-chief until 1812.
Domestically, Bailén quickly became studied through the lens of leadership formation. Reding’s handling of raw troops, his well-trained artillery, and his effective use of reserves became standard lessons for future Spanish officers studying Bailén in the royal military academies, influencing national tactics through the Spanish Civil War. Internationally though, Spain’s “War for Independence” lay in abeyance until twentieth-century Marxists resurrected their founder’s romanticizing of the guerrilla. Their certain faith in the inevitable triumph of armed peasants over even the doughtiest of professional militaries led them to not only whitewash these irregulars’ motivations, but also to overestimate their actual military effectiveness in asymmetrical warfare.
The Bailén campaign offers a more dynamic lesson at the operational level. Officers newly elevated to independent command need to be wary of more than just “the Peter Principle”, where promotion beyond competence means succumbing to operational paralysis in the face of new and varied concerns, laden with consequences, all demanding attention. Especially competent officers must also acknowledge that at necessary, even critical points in their missions, events will pass out of their control. Whether we choose to call it a leap of faith, a reliance on fortune, a submission to fate, or a trust in one’s star, it amounts to the same thing: Those officers who are unwilling to accept that phase and cling too tightly to their egos risk real failure that may carry severe consequences.
It is at the level of policy, however, that the campaign’s lessons are the most significant. By presuming too much on the unpopularity of the Bourbon family and on his incredible triumphs against even more formidable opponents, Napoleon cast Spain into the arms of its longtime enemy, unleashing a resistance movement possessed of an even greater collective will than he could ever muster. Such inconceivable consequences ultimately proved his undoing.
But Bailén’s more enduring warning concerns what happens after an outside power removes a government without a successor authority ready to stand in its place. In 1808, Napoleon destroyed the existing supreme authority in Spain but failed to understand how the Crown had, for centuries, balanced and limited profoundly distinct ethnic and regional identities — from the Basques and Navarrese to Andalusians and Catalans. Once the king was gone, civil authority devolved to juntas, cities, provinces, warlords, clerics, and even foreign patrons. With localized resistance came a revived understanding of, and commitment to, local distinctives. Spanish officers increasingly could not regard themselves any longer as servants of a unifying state, but rather as guardians of a nation — or a nation of nations — whose identity was now up for grabs.
The nature of Spain’s national catastrophe created both visionaries and opportunists among the initial resistance leaders. These men seeking the power to shape their own destinies enlisted their compatriots in noble and ignoble ventures. Not only did most prove loath to relinquish control, ego or a pressing emergency could justify its expansion. Less than two months after Bailén, Castaños sharply rebuked rival Gen. Gregorio de la Cuesta, a lukewarm patriot of dubious abilities who had been persuaded to revolt only after a mob had placed a noose around his neck. Now styling himself “general-in-chief,” de la Cuesta had arrested deputies critical of his military prowess while they were en route to the Supreme Junta, fearful that their presence would result in overturning the general’s shameless pretensions. Castaños called for the deputies’ immediate release, warning that such arrogant behavior threatened to establish “a military anarchy which, after spilling torrents of blood, will cause us to fall into the hands of our enemies and precipitate us into despotism and slavery.”
National security professionals have argued for more than two decades over versions of similar unresolved fragmentation in the aftermath of regime removal via externally sponsored transitions. Iraq, Libya, Afghanistan, and Syria each posed the same basic planning question in different forms: What happens when the old authority is destroyed faster than a new one can command obedience? One need not equate these cases or litigate them here to see that nature abhors a vacuum.
Planners are often seduced by the ease of the military operation and the allure of the tactical success that can lead to rapid victory over an enemy. But who in that new government can issue orders that soldiers, police, civil servants, and ordinary citizens will regard as binding or that can be supported by religious authorities through moral exhortation? Which nongovernmental civilian institutions should be preserved — and therefore co-opted — and which should be discarded? Which officers will conclude that loyalty to the new nation supersedes obedience to their old oath? The answers to these questions are the centers of gravity.
Spain shows that when these questions are left unasked, let alone unanswered, even an initially nonpoliticized officer corps can be drawn into deciding legitimacy for itself. From 1808 to 1814, Spanish officers — moved by self-interest, rivalry, honor, patriotism, ambition, or simple concern for their families — were forced to choose between unreasonable masters. In such an environment, traditional boundaries between military professional and politician become impossible to preserve. The officer who begins by defending the state often ends believing that only the army can save it.
The more crippled the institutions, the longer the process to repair a society will take, and inevitably, the harsher the initial reimposition of order. In the most debilitating cases, polities may need a new constitution to restore its health. National crises of this sort have heralded the arrival of a Caesar, a Cromwell, or a Bonaparte: military figures adept at reading the mortal condition of their societies, able to discern the foundations of a new order, and audacious in acting upon their vision. Yet even visionary generals rarely create a lasting political structure or an enduring social harmony, selflessly strengthening other institutions while their personal influence — with the military that established and supported it —is constrained within constitutional bounds. George Washington is the most prominent exception. It is mighty hard to build an institution stronger than the armed forces that have created it.
So it proved for Spain. From 1814 onward, it would be incredibly difficult for the now politicized officer corps to relinquish its self-appointed role as defender of national honor and restorer of independence. More than 40 times over the next five decades, pronunciamientos issued by senior officers forcibly installed regimes of varying constitutionality. These generated punctuated moments of political stability while failing to address, and undoubtedly contributing to, a pervasive atmosphere of cynical mistrust of both monarchical and liberal regimes. Neither the actions of the two short-lived republics nor those of the dictators Primo de la Rivera and Francisco Franco resolved these dilemmas, leading to Spain’s most recent pronunciamiento on the night of Feb. 23, 1981. There, however, the coup failed, the new constitutional order held, and the army’s claim to be the guardian of the state was broken.
Bailén therefore matters not only because it was Napoleon’s first great battlefield humiliation, but because it again illuminates the strategic cost of confusing tactical victory with political success. Trust cannot be created as fast as it is destroyed. When outside powers destroy the old order without establishing a suitable replacement, they should not be surprised when soldiers begin building one themselves.
Andrew Mitchell, who holds a doctorate from the Ohio State University, is a professor of history at Grove City College in Pennsylvania. He has over two decades’ experience researching and teaching Spanish and military history.
Image: Wikimedia Commons