The first combat of Bilbao (13-14 August 1812) saw a joint Anglo-Spanish force capture the Basque capital, but it was recaptured by the French only two weeks later.
In the summer of 1812 a British naval squadron under Captain Home Popham operated along the north coast of Spain, attacking a series of isolated French posts. The capture of Lequeitio (21-22 June 1812) and Castro Urdiales (6-8 July 1812) were followed by failed attacks on Portugalete (11 July 1812) and Guetarai, but these did serve to draw the French east.
Popham's next move was an attack on Santander, well to the west. This was carried out alongside the Spanish troops of José Ramón Rodil Campillo, a regular army officer who now commanded one of the guerrilla bands under Juan Díaz Porlier, and General Gabriel de Mendizabal, the commander of the Spanish Seventh Army also arrived towards the end of the siege. On the night of 2-3 August the French garrison broke out and joined up with General Caffarelli, commander of the French Army of the North, who then withdrew back towards Vitoria, where he expected to be attacked by Wellington.
After the fall of Santandar, Popham and Mendizabal decided to attack Bilbao, the capital of Biscay province and the main city in the Basque country. Mendizabel called up all of his available troops for the attack, although not all arrived in time. He led three battalions (two from Porlier and one newly raised unit) and marched east from Santander. Popham collected three battalions from Biscay (under Mariano Renovales), and landed them at Lequeitio, a few miles to the east. He then moved west to attack the fortified village of Portugalete, at the month of the river.
The three pronged assault quickly drew the French out of position. On 13 August the commander of the Biblao garrison concentrated all of his troops, including the garrison from Portugalete, against Mendizabal and Renovales. When the British reached the village they found it was undefended, and quickly occupied it. The French commander believed that he was in danger of being surrounded, and abandoned the fight, retreating east to Durango.
On the following day the French returned, after realising that the attacking forces weren't as strong as they had believed. However it was now too late, and the Spanish troops of Mendizabal and Renovales were able to hold them off. The French were forced to retreat, while more Spanish troops appeared at Bilbao. Mendizabal summoned the general junta of the Basque provinces to meet at Bilbao, and for a couple of weeks it looked as if the French might be about to be forced out of Biscay province.
This turned out to be premature. General Caffarelli managed to raise a field army of around 7,000 men, and advanced on Bilbao. He attacked on 27-29 August, and successfully forced the Spanish to retreat. Most of the Spanish troops escaped successfully, although Renovales suffered a defeat at Dima, not far to the south of Bilbao.