The Restoration War and Setubal (1640)
On 1 December 1640, a group of Portuguese conspirators stormed the royal palace in Lisbon and overthrew the Spanish viceroyalty, bringing sixty years of Iberian Union to an end. In Setubal, the defining episode of these events was the siege of the Fort of Sao Filipe – a fortress built by the Spanish themselves to control the city, which became the last stronghold of Spanish authority in the region.

Context: The Iberian Union (1580–1640)
The Loss of Independence
In 1580, the Portuguese royal House of Aviz died out. Following the death of King Sebastiao at the Battle of Alcacer-Quibir (1578) and the brief reign of Cardinal Henrique, the throne fell vacant. It was claimed by Philip II of Spain, who became Filipe I of Portugal. Thus began the Iberian Union – a period during which Portugal and Spain were united under the Habsburg crown.
Sixty Years under Spanish Rule
In formal terms, Portugal retained administrative autonomy: its own laws, institutions, and language. In practice, however, the Spanish crown intervened ever more aggressively in Portuguese affairs:
- Tax burden – rising taxes to finance Spain’s wars across Europe
- Military losses – Portuguese sailors and soldiers perished in Spanish conflicts
- Loss of colonies – the Dutch seized Portuguese possessions in Brazil, Africa, and Asia, while Spain failed to protect them
- Erosion of autonomy – Spanish officials increasingly replaced Portuguese appointees in key positions
The Construction of the Fort of Sao Filipe
It was during this very period, between 1582 and 1600, that the Fort of Sao Filipe was erected – a star-shaped bastioned fortress on the hill above Setubal. Commissioned by Philip II (who personally attended the laying of the cornerstone in 1582), designed by the Italian military engineer Giovan Giacomo Paleari Fratino with Filippo Terzi serving as chief engineer (construction began in 1590 and was completed in 1600 by Leonardo Torreano after Terzi’s death), the fortress served a dual purpose:
- Coastal defence – protection against pirates, English and Dutch privateers
- Control of the city – suppression of potential uprisings by the local population
The very placement of the fortress – on high ground, with cannon trained both seaward and toward the city – left no ambiguity about its second function.
The Coup of 1 December 1640
The “Forty Conspirators”
By 1640, discontent with Spanish rule had reached a critical point. A group of Portuguese nobles and military officers, known as the “Forty Conspirators” (Os Quarenta Conjurados), prepared a palace coup.
The timing was calculated: Spain was simultaneously waging the Thirty Years’ War in Europe and suppressing the revolt in Catalonia (June 1640). Madrid’s forces were stretched thin.
Events in Lisbon
On the morning of 1 December 1640, the conspirators stormed the Ribeira Palace (Paco da Ribeira) in Lisbon:
- Viceroy Margaret of Savoy was arrested
- Secretary of State Miguel de Vasconcelos – the most despised figure in the Spanish administration – was killed
- The people of Lisbon took to the streets in support of the coup
That same day, the Duke of Braganza was proclaimed King of Portugal under the name Joao IV. So began the Portuguese Restoration War (Guerra da Restauracao), which lasted until 1668 and concluded with the Treaty of Lisbon, in which Spain formally recognised Portuguese independence.
Setubal: The Siege of the Fort of Sao Filipe
The City Sides with the Insurgents
News of the coup in Lisbon spread rapidly. Setubal, located fewer than 50 km from the capital, learned of events within the first days of December 1640.
The city and its surroundings rallied to the new king virtually without resistance: the local population, like the majority of the Portuguese, supported the restoration of independence. The Spanish garrison in the city laid down its arms.
However, the Fort of Sao Filipe remained under Spanish control. Its commander, Dom Francisco de Almeida, refused to surrender.
The Siege
Portuguese forces, supported by the local populace, laid siege to the fortress. The position of the Spanish garrison was hopeless:
- Isolation – the city and surrounding area had sided with Joao IV
- No reinforcements – Spain could not (and did not) dispatch relief
- Popular pressure – the very inhabitants of Setubal, for whose suppression the fortress had been built, now surrounded it
The Surrender
Under the weight of circumstances, the fort surrendered – it was the last fortification in Setubal to go over to the insurgents. This fact underscores the defensive strength of the fortress: its walls, moats, and bastions enabled the garrison to hold out longer than any other strongpoint in the region.
The irony of history: a fortress built by Spain to control Setubal resisted not an invasion from without, but the very city it had been built to subjugate.
Consequences for Setubal
A Change of Function for the Fort

After the Restoration, the Fort of Sao Filipe passed into the hands of the Portuguese crown and was integrated into the national defence system. Its function changed: from an instrument of control over the city, it became a means of defending the city and coastline from external threats.
Throughout the subsequent decades of the Restoration War (1640–1668), the fortress served as a defensive position in the event of a Spanish counter-attack, although the main fighting took place along the land border – in the Alentejo and the north.
Economic Recovery
The restoration of independence allowed Portugal to regain control of its colonial trade and redirect tax revenue to its own treasury. For Setubal, as a major port and centre of the salt trade, this meant:
- The resumption of direct trading ties with England and Holland (both of which had supported the Restoration)
- An end to participation in ruinous Spanish wars
- Renewed investment in port infrastructure
The Anglo-Portuguese Alliance
In 1654, Portugal signed a treaty with England, reinforcing a long-standing alliance. In 1661 came the Marriage Treaty: Catherine of Braganza, daughter of Joao IV, married the English king Charles II. England became Portugal’s principal trading partner and military ally – and Setubal, as one of the kingdom’s key ports, benefited directly from this alliance.
The Restoration War: Key Dates
| Date | Event |
|---|---|
| 1580 | Beginning of the Iberian Union: Philip II of Spain becomes King of Portugal |
| 1582–1600 | Construction of the Fort of Sao Filipe in Setubal |
| 1 December 1640 | Palace coup in Lisbon; proclamation of Joao IV |
| December 1640 | Setubal sides with the insurgents; siege of the Fort of Sao Filipe |
| 1640–1668 | The Restoration War |
| 1654 | Anglo-Portuguese Treaty |
| 1661 | Marriage Treaty: Catherine of Braganza and Charles II |
| 13 February 1668 | Treaty of Lisbon: Spain recognises Portuguese independence |
Restoration Day
1 December is observed in Portugal as Dia da Restauracao da Independencia – a national holiday marking the Restoration of Independence. For Setubal, this date holds particular significance: the city preserves the memory of the siege of the Fort of Sao Filipe as its own contribution to the restoration of national sovereignty.
Image sources
- restoration-forte-sao-filipe.webp — Fort Sao Filipe — a key fortification of the Restoration War. Author: Diego Delso. License: CC BY-SA 4.0. Source
- restoration-setubal-1669-panorama.webp — Panorama of Setubal in 1669. Author: Unknown (17th century). License: Public domain. Source
- restoration-forte-sao-filipe-entrance.webp — Entrance to Fort Sao Filipe. Author: Diego Delso. License: CC BY-SA 4.0. Source
See also

- Fort of Sao Filipe
- Setubal and the Age of Discoveries
- Reconquista and the Medieval Period
- The 1755 Earthquake
- Castle of Palmela
The light is on for free. But someone has to clean the lantern.
☕ Support on Ko-fi