Battle for the Río San Juan de Nicaragua The Battle for the Río San Juan de Nicaragua was one of several important battles that took place during the Anglo - Spanish War , a subconflict of the Seven Years ' War which lasted from December 1761 until February 1763 . The conflict , which took place in July — August 1762 , began when William Lyttelton , the British governor and commander - in - chief of Jamaica , sent a naval expedition to Nicaragua with the primary objective of capturing the town of Granada . Background . Because it represented a potential route between the Atlantic and Pacific oceans as well as the possibility of expanding their colonization of Central America beyond the Miskito Coast , Nicaragua was a major target of attacks by the British during the 18th century . Due to the economic interests of the British in Central America , the Treaty of Friendship and Alliance was signed on March 16 , 1740 between King Edward I of the Miskito Kingdom and King George II of Great Britain of the Great Britain . Under the terms of the treaty , a protectorate was established over the Mosquito Coast and the British supplied modern weapons to the Miskito people . The Miskito Kingdom later aided Britain during the American Revolutionary War by attacking Spanish colonies and gained several victories alongside the British . Between 1739 and 1748 , the Kingdom of Great Britain and the Bourbon Spanish Empire had been at war over a series of trading disputes in a conflict known as the War of Jenkins ' Ear , which was later subsumed by the wider War of the Austrian Succession . Most of these disputes were more or less settled by the signing of the Treaty of Aix - la - Chapelle in 1748 and the Treaty of Madrid in 1750 . When the Seven Years ' War broke out in Europe in 1756 , Spain did not initially join either of the two coalitions of belligerents . The Spanish policy of neutrality was immediately tested on December 26 , 1756 when a British privateer , the " Antigallican " , captured the French ship " Penthievre " . When the British captain took both ships into the Bay of Cadiz , the Spanish authorities inpounded both ships . Spain insisted that the captured ship should be returned to France , along with the " Antigallican " which was awarded as compensation . This outraged the British , but no military action was taken . This incident marked the beginning of a decline in Anglo - Spanish relations . As the Seven Years ' War progressed , the neutral Spanish government became concerned that the string of major French losses at the hands of the British had become a threat to Spanish interests . On August 15 , 1761 , King Charles III of Spain and King Louis XV of France signed the Third Pacte de Famille . This treaty created an alliance between Spain and France and brought Spain into the ongoing war . By an ancillary secret convention , Spain became hurriedly committed to making preparations for war against Britain . The major objectives of Spain were the capture of Gibraltar and Jamaica from Britain . Britain first declared war against Spain on 4 January 1762 and on 18 January 1762 , Spain issued their own declaration of war against Britain . The British quickly captured Cuba and the Philippines in early 1762 . Also in early 1762 , William Lyttelton , the British governor and commander - in - chief of Jamaica , proposed a naval expedition to Nicaragua . The goal was to sail up the San Juan River to Lake Nicaragua and capture the town of Granada , which would effectively cut Spanish America in half as well as provide potential access to the Pacific Ocean . The first and greatest obstacle to success was to capture the Fortress of the Immaculate Conception . The conflict began in June 1762 , during the administration of interim Governor of Nicaragua Melchor Vidal de Lorca y Villena . Instigated and aided by the British expeditionary force , a group of Miskito Sambu filibusters attacked cocoa plantations in the Valley of Matina . The following month they raided many undefended settlements in Nicaragua , including Jinotega , Acoyapa , Lovigüisca , San Pedro de Lóvago , the mission of Apompuá near Juigalpa and Muy Muy , burning and looting the villages as well as capturing some Spanish prisoners . Many of the people they captured were sold as slaves to British merchants and transported to Jamaica . The combined British and Miskito Sambu expeditionary force headed towards the Fortress of the Immaculate Conception on the San Juan River in July . The attacking force consisted of two thousand men and more than fifty boats , while the soldiers at the fortress numbered only around a hundred . To make matters worse , the invaders threatened the region at a time when the commander of the fortress , Don José de Herrera y Sotomayor , was mortally ill . As he lay on his deathbed , Herrera ' s daughter Rafaela made a solemn oath to her father that she would defend the fortress at the cost of her life if necessary . The elder Herrera died some time between July 15 and July 17 , and Lieutenant Don Juan de Aguilar y Santa Cruz assumed temporary command of the garrison . The battle . The expeditionary force arrived at the fortress on July 26 , 1762 . At 4 o ’ clock that morning , the lookout on duty heard cannon fire from the east , in the direction of an observation post which was located at the junction of the Bartola and San Juan rivers . Shortly thereafter , the invaders captured the observation post and its defenders . The British commander learned from the Spanish prisoners that the fortress was in disarray due to the recent death of its commander . A few hours later , with his fleet anchored in the river , the British commander sent an envoy to demand the unconditional surrender of the fortress in exchange for the avoidance of further hostilities . The second in command of the garrison , a sergeant , was about to grant the request when the 19 - year - old Herrera intervened . Seeing what she perceived as the cowardly attitude of the defenders , Herrera chided : " Have you forgotten the duties imposed by military honor ? Are you going to allow the enemy to steal this fortress , which is the safeguard of the Province of Nicaragua and of your families ? " Animated by the spirit of her late father and ancestors and knowing the risk to her honor and virginity with the barbarity of the Miskito Sambu , she strongly opposed the surrender of the fort and insisting that each soldier take his place fighting . She ordered the gates of the fortress to be locked , took the keys and placed sentries . In response to the rejection of their demands , the British formed a skirmish line , believing that this would be sufficient to achieve the desired effect . Herrera , trained in the handling of weapons , fired one of the cannons and managed to kill the British commander with the third volley of cannon fire . Enraged by the death of their leader , the British hoisted their battle ensign and began a vigorous attack upon the fortress which continued throughout the night . The garrison , energized by Herrera ’ s heroism , mounted a fierce resistance which inflicted great losses to the British men and boats . At nightfall , Herrera ordered the troops to throw some sheets soaked with alcohol into the river on floating branches and set on fire . The current dragged the burning material towards the enemy craft . This unexpected action forced the invading British troops to suspend their attack for the rest of the night and retreat to defensive positions . The next day the British laid siege to the fortress , but with little progress and many casualties on their side . Inspired by Herrera ' s acts of heroism , Lieutenant Juan de Aguilar , the " pro tempore " garrison commander , led the defenders to victory in a battle that lasted six days . Herrera handled the cannons of the fortress and the Spanish managed not only to defend the strategic position but also to defeat a much larger and better trained military force . The British finally lifted their siege and retreated on August 3 , 1762 . They withdrew to the mouth of San Juan River , where their presence impeded the flow of shipping into the Caribbean Sea for some time . Aftermath . Fortunately for the defenders of the fortress , Spain and Britain began peace negotiations ( in Fontainebleau on November 3 , 1762 ) , which culminated in the Treaty of Paris on February 10 , 1763 . Cuba and Manila , which had been captured by the British , were returned to Spain and the Spanish ceded Florida to the British . After Spain entered the American Revolutionary War in 1779 , Major General John Dalling , the British governor and commander - in - chief of Jamaica , proposed a second naval expedition to Nicaragua . During this expedition , which took place in 1780 and later became known as the San Juan Expedition , Colonel John Polson and Captain Horatio Nelson led a British attack against the fortress . At the time , the Spanish garrison consisted of 228 men under the command of Juan de Ayssa ( who later served as Governor of Nicaragua from 1783 – 7 ) . The expeditionary force succeeded in capturing the fortress on April 29 , 1780 , despite the fact that it consisted of only 200 men . The 22 - year - old Nelson , in command of " HMS Hinchinbrook " , was responsible for leading his men through dense jungle to attack the fortress from a hill in the rear . The British captured the fortress and occupied it for nine months , finally abandoning it in January 1781 .