The project for a modern fortification to defend this stretch of the Portuguese coast dates back to the 14th century, with the construction of the Fort of Santiago do Outão, intended to control the entrance to the river bar and access to the medieval town. Aiming to expand this defense, during the reign of D. João III (1521-1557), Brás Dias was given a regiment to be the administrator of the works of the Plaza and Castle of Setúbal (July 31, 1526). Financial difficulties, which even led to the abandonment of overseas positions in North Africa (Fortress of Azamor, Fortress of Arzila, Fortress of Alcácer-Ceguer and Fortress of Safim), may have delayed the development of these works.
Dating back to the time of the Philippine dynasty, its relevance is demonstrated by the fact that the sovereign Philip I (1580-1598) himself attended in person, in 1582, the laying of the foundation stone of the new fortification, designed by the Italian architect and military engineer Filippo Terzi (1520-1597). This engineer worked on the works until mid-1594, when he signed a plan and section of the fortification (8 July 1594), which was sent to the Spanish War Council. After his death, the military engineer and architect from Cremona, Leonardo Torriani, was appointed to carry out the works, and they were completed in 1600.
In the context of the restoration of independence, during the reign of King John IV (1640-1656), the Governor of Arms of Setúbal, João de Saldanha, expanded this defence by adding a low battery between 1649 and 1655. It is believed that this new structure was intended to make up for the lack of artillery in covering river access to the port.
In the 18th century, the chapel inside acquired its tile covering, designed by Policarpo de Oliveira Bernardes (1736). During the Pombaline consulship (1750-1777), it was not immune to the earthquake of 1755 and was used as a School of Artillerymen.
In the mid-19th century, a fire destroyed the Casa do Comando, then the residence of the Governor of Arms of Setúbal.