Spanish police say they have shot dead five suspected terrorists in the town of Cambrils in a second vehicle attack, after an earlier one in Barcelona killed 13 people and injured dozens.
The men were linked to the Barcelona attack, police say.
Police are still hunting the man who drove his van into crowds on Las Ramblas in Barcelona on Thursday.
Spain’s PM Mariano Rajoy described it as a “jihadist attack”, which so-called Islamic State said it had carried out.
Mr Rajoy has announced three days of national mourning and a minute’s silence will be held later on Friday.
Seven people, including a police officer, were wounded when a car was driven into them early on Friday, Catalan emergency services said. One person is in a critical condition.