A driver swerved a van onto a pedestrian area Thursday in Barcelona’s historic Las Ramblas district, ramming into crowds and leaving at least a dozen people dead and scores of others injured scattered along a stretch of tree-shaded sidewalk. Authorities described the incident as a terrorist attack.

Joaquim Forn, the interior minister of the Catalan regional government, reported in a Twitter message that 13 people were dead. The government later revised the death toll to 12.

Some of those injured were in serious condition, raising the possibility that the death toll could rise. Earlier, Spanish police described the carnage as “massive.”

The Islamic State claimed responsibility for the attack, the terrorist group’s Amaq news agency reported, according to the SITE Intelligence Group, which monitors extremist activity.

Hours after the initial attack unfolded, central Barcelona was still on lockdown, and it was unclear whether attackers were still at large. The Catalan Interior Ministry said late Thursday that a car broke through a police checkpoint outside Barcelona and injured two police officers. It was not immediately clear whether the incident, which took place near the town of Sant Just Desvern, just west of Barcelona, was connected to the attack.

Authorities announced that two suspects were in custody.

“There have been people arrested, and this investigation is still ongoing,” Carles Puigdemont, president of the Catalan regional government, told reporters in Barcelona, noting that two suspects were in custody. “Catalonia will always prevail in the face of terrorism. We will always stand for democracy and freedom. We will always be united. Be assured that democracy will always win against barbarism.”

He said that 80 people were hospitalized.

Spanish police did not immediately give details on the driver or other aspects of the incident.

Spanish news media, citing police sources, reported that one person was killed in a shootout after running a police roadblock on the outskirts of the city, but there was no immediately official confirmation of that.

Catalan police said there was no hostage situation in a bar in the city center, denying rumors that quickly spread in the confused hours after the van plowed through the crowd.

Catalan regional police later said they were evacuating people from the Las Ramblas area as they conducted a manhunt following the attack.

Spanish King Felipe VI vowed on Twitter that Spain would not be “terrorized” by murderers and criminals. “All of Spain is Barcelona,” he wrote. “Las Ramblas will return to being for everyone.”

Cities around the world have been on higher alert for vehicle-linked attacks after terrorist crashes in London, Stockholm, Berlin and other places in the past year.

Islamic State supporters celebrated the Barcelona attack on Thursday and promoted previous threats made against Spain, according to the SITE Intelligence Group.

The Islamic State, also known as ISIS, has called on supporters to carry out attacks using vehicles. The group has claimed responsibility for car attacks carried out in Europe, as well as on the campus of Ohio State University last year.

The attack drew offers of assistance from around the world, including the United States.

“The United States condemns the terror attack in Barcelona, Spain, and will do whatever is necessary to help. Be tough & strong, we love you!” President Trump wrote on Twitter.

Secretary of State Rex Tillerson said U.S. authorities would offer any help they could.

Video posted on social media showed at least four people sprawled on the sidewalk, some apparently not moving. Hats, handbags and other items were strewn nearby. Some people ran screaming from the scene.

The white van that veered into the pedestrians came to stop with its front scratched and crumpled.

“All of a sudden, the police just shouted at everyone, telling them just to run. There was a really loud kind of crashing noise. I didn’t stop to look back,” Ethan Spieby, a witness caught up in the commotion, told the BBC.

He said he was holed up in a church with about 80 tourists and locals. “They have locked the doors, and I think the police are outside. We’re just waiting in here right now to hear more news. It’s quite scary to be caught up in it.”

Andrew Roby, 35, a tourist visiting from Washington, told The Washington Post he saw a small white van that had plowed into pedestrians on the busy central street, lined with bars, cafes and shops. “All of sudden, everyone started running, so we ran, too.”

Roby said he saw several people, apparently wounded, lying in front of and beside the van. “We saw people on the ground. . . . I heard a bunch of people screaming.”

Tom Markwell, another American tourist, told the BBC that he saw a white van “going entirely too fast. It looked to me as if he was going left to right, hitting people with the little stand. . . . All of a sudden, people were just screaming and running.”

Police immediately cordoned off the area in the center of Barcelona. Stores and restaurants were ordered closed.

Las Ramblas is one of the city’s top tourist zones, with a wide pedestrian promenade flanked by roadways on either side.

The bustling avenue in the heart of Barcelona was packed with tourists at the height of vacation season. Spain has been largely spared major terrorist incidents since a 2004 attack on the Madrid commuter train system, but authorities have been concerned about terrorist risks for some time as neighbors were repeatedly struck.

The Catalonia region of Spain has also faced repeated terrorist attacks over decades from the ETA Basque separatist group. Catalonia is planning an independence vote Oct. 1 over the objections of the national government in Madrid, which says it is unconstitutional.

In July 2016, a truck was driven into Bastille Day crowds along a seaside corniche in the southern French city of Nice, killing 86 people. In December 2016, 12 people were killed when a driver used a hijacked truck to drive into a Christmas market in Berlin.

In March, a man in a rented SUV plowed into pedestrians on London’s Westminster Bridge, killing four people before he ran onto the grounds of Parliament and fatally stabbed a police officer. A month later, a rejected asylum seeker from Uzbekistan crashed a truck into a department store in Stockholm in an attack that left five people dead.

Murphy reported from Washington. Mark Berman and David Nakamura in Washington contributed to this report.