TUNIS — At least one gunman disguised as a vacationer attacked a placid seaside resort in Tunisia on Friday, killing at least 37 people at a beachfront hotel before he was shot to death by security forces.
It was the second major terrorist attack in a little more than three months targeting the Tunisian tourist industry. It sent shockwaves through the country, which was still recovering from the first assault, a massacre at a museum in the heart of the capital in March. President Beji Caid Essebsi rushed to the resort and promised tough new security procedures.
The audacity of the assailant, armed with a Kalashnikov rifle, suggested a sharp escalation from the relatively low-level political violence that has bedeviled Tunisia since its Arab Spring revolt four years ago.
Government officials and witnesses offered conflicting accounts of the assault, with some saying that two gunmen, who had possibly come ashore in a rubber dinghy, had ambushed tourists at the Imperial Marhaba Hotel in Sousse, which is popular with German vacationers.
Others said that there was a single gunman but that the police were searching for possible accomplices. There were unconfirmed reports that the violence had extended to a second hotel.
At least 20 people were wounded in the attack, including five British tourists and five Tunisians, who were being treated at a city hospital, Tunisian news media reported.
The nationalities of the other victims were not immediately clear, but some witnesses said many appeared to have been foreigners, including some children. The victims were gunned down on the beach, at the hotel pool and in the lobby. Some said it took the police and security officers at least 30 minutes to respond after the shooting started just before noon.
“I can’t understand why they didn’t arrive earlier,” Khmais Bouzayane, 45, a longtime employee of the hotel, said by telephone. “I lived in an unimaginable terror. I hid near the pool, in the engine room below the ground.”
Hours after the assault, he said, police officials were still combing through the hotel grounds, and medical crews were “still picking bodies from the sea — the sea has the biggest number of bodies.”
No group claimed responsibility in the hours after the attack. The Tunisian authorities have struggled to suppress a small but violent Islamist insurgency that has sprung up in the four years since the uprising that forced out the former president, Zine al-Abidine Ben Ali and set off the Arab Spring.
But Islamist extremist groups have been threatening attacks against the Tunisian government, its security forces and its institutions for months. They have frequently mounted attacks against police and army units over the past two years, but appeared to turn their focus recently to the tourism industry, which offers easy targets and is vital to the Tunisian economy.
Prime Minister Habib Essid said in a recent interview that the aim of the extremists was to damage the economy and derail Tunisia’s democratic transition.
The attack in Sousse, Mr. Ben Ali’s hometown, comes just over three months after two gunmen killed 22 people — 21 of them foreign tourists, in a mass shooting at the Bardo National Museum in Tunis. The two men had been radicalized in Tunisia and trained in an Islamist militant camp in Libya in the weeks before the attack.
In Sousse, the assailant who was killed wore black shorts and a T-shirt, and his body lay sprawled on the street, his assault rifle beside him. He dressed as a tourist and had carried the rifle concealed in a large beach umbrella, said Rafik Chelli, secretary of state for the Interior Ministry. The police identified him as a young Tunisian from the town of Kairouan with no prior police record, Mr. Chelli said.
The tourism minister, Salma Elloumi, who has worked conspicuously to support the industry and encourage foreign visitors, said on national radio that the Sousse attack was a “catastrophe” for Tunisia.
Legislators immediately called for new measures to stop such attacks. The leader of the Popular Front movement, Hama Hammami, called the Sousse assault a “hideous crime” that was aimed at terrorizing Tunisians. Two politicians with the Popular Front were assassinated in 2013 by Islamist extremists.
Frank-Walter Steinmeier, Germany’s foreign minister, condemned the attack on the resort as “cowardly” and expressed his sympathy to the families of the “many people we must expect will be victims of this attack.”
Several German tour companies offer vacation packages to the Imperial Marhaba Hotel, but the Foreign Ministry had no immediate information about whether any of its citizens were among the victims. A spokesman said the German Embassy in Tunis was in “close contact” with the Tunisian authorities.