# Luso–Leonese War (1130–1137)

The Luso–Leonese War of 1130–1137 was an armed conflict between the Kingdom of León and the County of Portugal which took place primarily in the Kingdom of Galicia (part of the Kingdom of León). This war took place during the reigns of Alfonso VII and Afonso Henriques, and was caused by the territorial claims of Afonso over Galicia and the idea of forming an independent Portuguese kingdom, an objective that would later be achieved after the Treaty of Zamora in 1143. The war ended with the signing of the Treaty of Tuy in 1137.

## Background

In 1128, Afonso Henriquez defeated Theresa and Count Fernando Perez de Traba at the Battle of São Mamede. After this battle, Afonso Henriques became the new Count of Portugal, with the support of the Portuguese nobility. He did not recognise the royal authority of his cousin Alfonso VII of Leon. After obtaining authority over the territory of the County of Portugal, he intended to expand the county beyond its horizons, towards the north. The plan was to capture Tuy, Ourense and other Galician towns, which had previously been governed by Theresa and Henry of Burgundy before being confiscated by King Alfonso VII of Leon. Two years after taking the throne of the county, he began his military campaign to take the throne of, this time, the Kingdom of Galicia belonging to the Kingdom of Leon.

## War
### First Campaign of Galicia (1130)

In 1130, Afonso Henriques decided to take advantage of the recent conflict between León and Navarre to carry out an organised attack on Galicia. Alfonso VII, being busy in Navarre, had to send a message to the Galician nobles in order that they should take care of formulating an organised defence to stop the Portuguese attacks on their territory. However, due to internal discord and conflict, many Galician nobles renounced their loyalty to Alfonso VII to join Afonso Henriques' conquering initiative, which made it possible for Afonso Henríquez to emerge unscathed from his campaigns.

### Truce and rebellion of Bermudo Pérez de Traba (1131)

Theresa of Leon, ex-governor of the County of Portugal, died in 1130, so all opposition to Afonso Henriques (loyal to Theresa) was eliminated from the county. By this date a truce was established between the Portuguese and Leonese. In 1131 Fernando Pérez de Traba was in Portugal to attend the funeral of his lover in the Cathedral of Braga, in the presence of the Bishop of Porto, Paio Mendes, his former rival, the Count of Celanova, the Archdeacon Telo and some other nobles and clerics even donated to the Cathedral of Coimbra a property in São Pedro do Sul, which had previously belonged to it and was given to it by Theresa and delimited by Afonso Henriques. Fernando Pérez was the brother of the lord of Viseu and Seia, Bermudo Pérez de Traba, who had been married to a sister of Afonso Henriques since the time of Theresa. From the castle of Seia, in the Sierra de la Estrella, he decided to help his brother against the young prince. The duke tried to start a rebellion among the nobles who were unfaithful to Afonso, but reacted quickly and went with his host to Seia, from there expelling both Bermudo and Fernando Pérez de Traba from the territory. Both joined the service of Alfonso VII and would later fight against Afonso. However, as late as October 1131, Bermudo Pérez went to the court of Afonso Henríquez, which shows that the relations between the two were not as affected as it might seem.

### Second Campaign of Galicia (1132)

The war resumed in 1132 and it was not until 1135 that new Portuguese campaigns in Galicia ceased. The Portuguese entered through the northern region of Limia. However, there they were defeated by the soldiers of Rodrigo Vélaz and Fernando Pérez de Traba, and were forced to return to Portugal.
However, when Alfonso VII was preparing to launch a counteroffensive against the Portuguese forces, a revolt broke out in his domains led by Count Gonzalo Peláez, who was defeated and imprisoned in the castle of Aguiar. From there he fled and took refuge in Portugal, where he was welcomed by Afonso, who gave him several lands.

### Third Campaign of Galicia (1133)

Afonso Henriques did not give up his intentions regarding Galicia. In 1133 he crossed the Minho again and took control of the region of Límia, in whose castles he placed new mayors and also built a new castle in Celmes, from which he left well garrisoned with men and supplies, then returning to Portugal. The castle, however, was quickly attacked by Alfonso VII and taken before reinforcements from Portugal could arrive. Its occupants were imprisoned, and the region of Limia was thus lost.
Alfonso VII then retired from Limia to deal with important political issues, since Alfonso I of Aragon had died and on July 4, 1135, Alfonso VII in the Cortes meeting in Leon assumed the high title of Imperator totius Hispaniae (Emperor of All Spain). The ceremony included tributes from the new King of Aragon Ramiro II, the King of Pamplona García Ramírez, Count Ramon Berenguer IV of Barcelona, and others but not Afonso Henriques, a bold omission that revealed his repudiation of his cousin's authority. Instead, he headed south to found the castle of Leiria in December, a vanguard for Coimbra, whose mandate was supposed to help protect the kingdom from Muslim attacks coming from Santarém, as well as threatening Muslim territory.

### Alliance with Navarre. Fourth Campaign of Galicia (1137)

After the defeat of Celmes, Afonso Henriques began a project of recruitment, donation of lands, granting of town charters, restoration of churches and monasteries and administration of justice.
In 1137, the King of Navarre died and was succeeded on the throne by Garcia Ramírez, who refused to pay allegiance to Alfonso VII and so war broke out between the two. Afonso took the opportunity to establish an alliance with Garcia and thus invaded Galicia once again. However, Alfonso VII was not alone: he allied with Ramon Berenguer IV. Upon entering Galicia, Afonso's army was joined by numerous Galician nobles attached to Portugal. The Count of Tuy Gómez Nuñez de Pombeiro and the Count of Límia Rodrigo Pérez de Traba were supporters of Afonso Henriques and sided with him, but the mayor of Allariz Fernando Anes vigorously defended his castle.
Afonso returned briefly to Portugal to reinforce his army and then, heading towards the Sil River, the Count of Sarria Rodrigo Vélaz and Fernando Pérez de Traba faced him with their hosts but both were defeated at the Battle of Cerneja.
Galicia was almost entirely occupied by Portuguese forces until Afonso received alarming news from the south: threatened by the attacks of Paio Guterres, the Muslims, commanded by Esmar, were preparing to attack Leiria. However, informed of the defeat of his vassals at Cerneja and negotiating peace with the King of Navarre, Alfonso quickly went personally to Galicia with a small army and reconquered Tuy, Toroño and Límia. He subsequently summoned the Galician nobles and the Archbishop of Santiago de Compostela to pool their treasury and join him on a large-scale military expedition into Portugal.
Strongly threatened both from the south and from the north, Afonso Henriques then went to Tuy accompanied by the archbishop of Braga and the bishop of Porto to propose peace to his cousin, the latter accompanied by the bishops of Segovia, Tuy and Ourense. Finally, Alfonso VII decided to accept the peace proposal of his cousin Afonso Henriques. This peace treaty was named the Treaty of Tuy. However, Afonso Henriques would ignore its terms.

## Aftermath

The peace did not last long: Afonso invaded Galicia again just two years later, in 1139. He attacked through Tuy and entered Toroño. Alfonso VII responded by invading Portugal and heading to the Vez with a Galician army. Both leaders met at the castle of Penha da Rainha. According to the Chronicle of the Goths [pt], Afonso won and captured the brother of the Leonese monarch, Bermudo Pérez de Traba and other supporters of Alfonso VII. But, according to the Chronica Adefonsi Imperatoris, the Kingdom of Leon won the battle and the Portuguese were the ones who asked for peace. Whatever the case, both exchanged prisoners and returned to peace.
This solved the problem of Portuguese independence for a very short time, since Afonso proclaimed himself king of Portugal after winning the battle of Ourique against the Almoravids in the same year. Alfonso VII recognized him as king in 1143 by the signing of the Treaty of Zamora, under the condition that he would remain a vassal of the emperor. However, it was not until 1179 that Pope Alexander III recognized him as an independent king, accepting his vassalage.