On the morning of 5 October 1804, when the Spanish fleet – led by José Bustamante y Guerra – was close to Cape Santa María, off the Algarve in Portugal, and just a day away from arriving in Cadiz, the frigates Medea, Mercedes, Clara and Fama were hit by four British Navy frigates: The Indefatigable, Lively, Amphion and Medusa. Following the commander's refusal to surrender and hand over the funds they were carrying, the fighting began. Shortly after, a direct hit by a cannonball to the magazine, where the gunpowder was stored, caused the Mercedes to explode: The ship, her cargo and the funds she was carrying sank to the bottom of the sea and the lives of 275 people were lost.
We know the story of what occurred that day thanks to the testimony of eyewitnesses such as Miguel de Zapiain, commander of the frigate Fama, who wrote a detailed account of what happened a few days after the event; that of Diego de Alvear, army general and commander of the frigate Medea, who recorded in his logbook the shocking story of the sinking and the tragic loss of his wife and seven of their children; and the magnificent description left to us by General Tomás de Iriarte whose memoirs tell of this event which he experienced when he was ten. This event was also immortalised in the novel Trafalgar, the first in the series of Episodios Nacionales (National Episodes) – one of the best known by Benito Pérez Galdós – in which Marcial, the protagonist of the story and enlisted aboard the frigate Fama, recalls what happened a year before the tragedy of Trafalgar.