Police have shot dead the van driver behind the Barcelona terror attack, authorities in Catalonia said.

Younes Abouyaaqoub, 22, was gunned down after being cornered in Subirats, about 30 miles west of Barcelona, on Monday.

The Moroccan was wearing a fake explosives belt and shouted “Allahu Akbar” before being killed, according to local reports.

Police said eight suspected terrorists connected to the attacks in Barcelona and Cambrils are now dead, while four suspects are in custody.

At least two extremists died on Wednesday in an explosion at a house in Alcanar, where explosives were being prepared, while six were killed by police.

Thirteen innocent people died and more than 100 were injured on Thursday when a van ploughed into pedestrians in Las Ramblas, a busy tourist area of Barcelona.

Younes Abouyaaqoubis was shot dead by Spanish police (Mossos/AP)

Joaquim Forn, head of home affairs in Catalonia’s regional government, said on Monday that “everything indicates” Abouyaaqoub was behind the wheel.

Police said he stole a car and killed its owner as he made his getaway after fleeing the carnage in Las Ramblas on foot.

He had been the only at-large member of the 12-strong terror cell behind the attacks in Barcelona on Thursday and in the seaside town of Cambrils early on Friday.

One person was killed in the Cambrils attack, in which terrorists wearing fake suicide belts drove an Audi A3 into pedestrians, bringing the death toll to 15.

Police said Abouyaaqoub walked around Barcelona for about 90 minutes after the van attack before hijacking a Ford Focus, stabbing its owner, Pau Perez, and driving away with his body still inside.

Police officers search a truck as they stand guard in a security checkpoint at the road entrance of Ripoll, north of Barcelona (Francisco Seco/AP)

Abouyaaqoub rammed the car through a police checkpoint on Friday night then dumped the vehicle two miles away, and had fled by the time officers found it with Mr Perez’s body still inside.

Police believe the explosion prevented the terror cell from carrying out what would have been a deadlier attack.

Detectives are reportedly probing claims the cell was radicalised by an imam with links to the Madrid train bombers and an area in Belgium known as a hotspot for Islamic State recruiting.

Spanish newspaper El Pais said Abdelbaki Es Satty was imam at one of the two mosques in Ripoll, north-east Spain, near the French border and around 62 miles from Barcelona.

All the main suspects are believed to have lived in the small town.

Police officers stand guard next to flags, flowers, messages and candles to the victims on Barcelona’s historic Las Ramblas promenade (Emilio Morenatti/AP)

Es Satty was reportedly friends with some of those jailed for the Madrid train bombings in 2004, having spent four years in prison himself for drug trafficking and breaking Spanish immigration laws, the newspaper said.

He also spent several months looking for work in the Vilvoorde district north of Brussels, the region’s mayor Hans Bonte told Belgian newspaper De Morgen.

Police are investigating his role in radicalising the younger members of the cell before he was reportedly killed in the explosion in Alcanar, 124 miles south of Barcelona.

Some 34 nationalities were among those wounded in the attacks in Las Ramblas and Cambrils, around 70 miles south west of Barcelona.

Victims of the atrocity in Barcelona have been identified as British/Australian, Italian, Portuguese, Belgian, Spanish, Spanish/Argentine, Canadian and American.

They included seven-year-old Julian Cadman, a dual British-Australian national who was separated from his mother on Las Ramblas during the massacre.

Paying tribute to the youngster, his family said: “He was so energetic, funny and cheeky, always bringing a smile to our faces.”