The Battle of Roncesvalles (778 AD) was a pivotal rear-guard action where Charlemagne's army, retreating through the Pyrenees, was ambushed by Basque forces. Immortalized in The Song of Roland, this historical defeat transformed into a legendary tale of heroism and betrayal, shaping medieval literature.