The whole church had a military function, since Vinaròs did not have a castle or fortress to protect the town. It consists of a sloping wall at its base, and some corridors on top of the lateral chapels, that served as a guard’s footpath. There is access to these parts directly form the nave of the church (La Virgen del Rosario Chapel) and from the bell tower. The building had defensive functions during the expulsion of the Moors; during the reign of Philip IV, its purpose was to defend the coast from the attacks of the Turkish pirates and corsairs; during the Carlist wars and the latest quarter of the nineteenth century, the church became the headquarters of the commander Jovellar. We should note the parapet walk and the liberal wall.