Spanish police shot and killed Younes Abouyaaquob, 22, in the small town of Subirats. Officials found a fake suicide bomb vest on the man after deploying a robot. (Raul Gallego Abellan for The Washington Post)

The driver of a van that careened through throngs of revelers in a tourist zone here last week was shot dead by police on a quiet country road Monday afternoon, capping a four-day manhunt for the last member of a 12-person terrorist cell likely led by a mysterious imam.

After receiving a tip from locals who spotted a suspicious character hiding in the vineyards around the village of Subirats, an hour’s drive west of Barcelona, rural law enforcement officers, accompanied by Catalan police, confronted Younes Abouyaaqoub.

Josep Lluís Trapero, chief of the Catalan National Police, said Abouyaaqoub threw open his shirt to reveal what officers believed was a suicide bomb belt around his waist.

The chief said Moroccan-born Abouyaaqoub then shouted “Allahu akbar,” or God is great in Arabic, and police shot him dead.

Authorities said Monday that forensic evidence, security camera images and a witness led them to conclude that Abouyaaqoub was the driver of the van that plowed through hundreds of pedestrians in a crowded Las Ramblas street on Thursday afternoon.

What we know about the two vehicle attacks in Spain

Spanish authorities said Monday that the death toll had risen to 15. Scores were wounded, some seriously.

Thirteen people were killed by Abouyaaqoub in his vehicular assault on La Rambla, a world-
famous avenue of cafes, shops, and stately old hotels in the heart of Barcelona.

An hour after the van attack, police say Abouyaaqoub killed another man to steal a getaway car. His accomplices, fleeing a police roadblock, ran over a woman.

Of the 15 people killed, two were children. Six were Spaniards, three Italians, two Portuguese. There was also a Belgian, a Canadian and dual citizen of Australia and Britain. One was an American, Jared Tucker, on his honeymoon.

After Abouyaaqoub was shot dead by police, a bomb squad deployed a robot to get near the prone body and discovered that the suicide vest was a fake, officials said.

The terrorist attack was the worst in Spain since the Madrid train bombings of 2004, when 191 people were killed and 1,700 were injured.

The Islamic State asserted responsibility for the Barcelona attack. Catalan police said that it is possible the terrorist cell, composed of Moroccan-born youths and young men, was inspired or steered by Islamic State actors, but that the investigation was ongoing and definitive links have not been established.

Security camera images released Monday by police showed Abouyaaqoub making his escape on foot through Barcelona’s La Boqueria market after the attack.

Those images were given to the public on Monday and probably led to the assailant being identified up in the mountain vineyards.

Catalan Justice Minister Carles Mundo identified Abouyaaqoub’s latest victim as Pau Perez, who was found dead in his Ford Focus several miles from the scene of the van attack. Police said that Abouyaaqoub knifed Perez to death when he stole his car to escape after the van attack. He dumped Perez into the back seat and drove away.

Abouyaaqoub then rammed through the barricades at a police checkpoint as officers fired on the car, authorities said. That vehicle was found abandoned a few miles away with Perez’s body still in the back seat.

Where Abouyaaqoub spent the last four days is unknown.

Trapero, the Catalan National Police chief, told reporters that authorities found DNA remains of at least two people killed in an explosion the day before the attack.

Trapero said it was likely that one of the bodies found at the explosion site was Abdelbaki Essati, a Muslim cleric who is suspected of radicalizing young men in the mountain town of Ripoll and organizing the terrorist cell.

Essati, a Moroccan national who lived in Ripoll for the last two years, served as imam in a mosque, where he taught the Koran and the Arabic language. Police revealed Monday that he was a convicted drug trafficker who had served time in the Castellon prison outside Valencia from 2010 to 2014.

Carles Puigdemont, president of Catalonia, told The Washington Post that police here were not given timely information by the Spanish federal government and were in the dark — until now — about the imam’s time in prison.

While serving his sentence in prison, Spanish media reported that Essati may have met Rachid Aglif, known as “the Rabbit,” one of the main plotters of the 2004 Madrid bomb attacks.

Ali Yassine, the director of the mosque in Ripoll, said that Essati was paid about $1,000 a month to serve as imam. Local benefactors paid his rent and helped with groceries.

Yassine told The Washington Post that he had given Essati’s name to local police more than a year ago as part of standard security protocol to keep a closer eye on Muslim preachers. But authorities did not flag Essati on a watch list even though he had a conviction for trafficking drugs.

If only authorities had alerted the Muslim elders in Ripoll that Essati was a convicted drug smuggler, the Moroccan families say, he would have been fired as imam and would never have had the chance to radicalize their sons.

“We have trusted the mosque and the authorities and send our children to learn about Islam and Arabic. How could they allow such a criminal and monster to get involved with our children?” said the aunt of Moussa Oukabir, one of the cell members. The aunt spoke on the condition of anonymity because she feared a backlash for what her relatives did.

“We must find out what has happened to them, so we can make sure not to lose the next generation of our children as well,” she said.

Police had another chance to stop the terrorist cell members before they struck — after a large explosion occurred Wednesday.

For almost 24 hours, until the van attack, police assumed the explosion was caused by criminals manufacturing methamphetamine.

Authorities said they investigated the blast site as quickly as possible. On Monday, police said they found 120 propane canisters at the site in Alcanar, about a two-hour drive south of Barcelona, alongside explosive material that has been employed in bombs.

Police concluded that the material and propane tanks were to be used in the attack on Barcelona’s crowded La Rambla promenade or at another site in the city.

At the bomb house, police said they also found remote-controlled detonators.

Raul Gallego Abellan in Subirats and Angel García in Barcelona contributed to this report.