Smoke rises from the Intercontinental Hotel during an attack in Kabul

Gunmen stormed a luxury hotel in Kabul and killed at least six persons, including a foreigner, sparking a 12-hour battle that left terrified guests scrambling to escape and parts of the building ablaze.The Taliban claimed responsibility for the attack on the six-storey Intercontinental Hotel on a hilltop overlooking the Afghan capital. People trapped at the top of the building tied bedsheets together and climbed over balconies to escape the overnight assault.

One lost his grip and fell in dramatic television footage by Afghanistan’s Tolo News station, which also showed black smoke and flames billowing from the top of the hotel.

Special forces were lowered by helicopters during the night onto the roof of the landmark 1960s building, with Afghan security forces killing four attackers in the hours- long assault, the interior ministry said.

“Five Afghans and one foreigner have been killed,” interior ministry deputy spokesman Nasrat Rahimi told AFP today, adding around 150 people were rescued including more than 40 foreigners.

“The body of the foreigner, a woman, was recovered from the sixth floor as the last attacker was being killed,” he added.

An official with Afghanistan’s spy agency put the number of wounded at eight, while the interior ministry said six.

Officials said four gunmen burst into the hotel, which is not part of the global InterContinental chain, last night, opening fire on guests and staff and taking dozens of people hostage.

The Taliban claimed responsibility for the latest assault in the war-torn capital via an email from spokesman Zabiullah Mujahid. The interior ministry had earlier blamed the Taliban-affiliated Haqqani network.

It followed security warnings in recent days to avoid hotels and other locations frequented by foreigners. Kabul has become one of the deadliest places in Afghanistan for civilians, with the Taliban and the Islamic State group both stepping up attacks.

It was not clear how many people had been inside the hotel.

During the siege, a guest hiding in a room said he could hear gunfire inside the building, where dozens of people attending an information technology conference on Sunday were staying.

“I don’t know if the attackers are inside the hotel but I can hear gunfire from somewhere near the first floor,” the man, who did not want to be named, told AFP by telephone.

“We are hiding in our rooms. I beg the security forces to rescue us as soon as possible before they reach and kill us.”                 His phone has been switched off since then.

Afghan Telecom regional director Aziz Tayeb, who was attending the IT conference, said he saw the attackers enter the hotel.

“Everything became chaotic in a moment. I hid behind a pillar and I saw people who were enjoying themselves a second ago screaming and fleeing like crazy, and some of them falling down, hit by bullets,” Tayeb told AFP.

Local resident Abdul Sattar said he had spoken by phone to friends who are hotel staff and had been trapped inside.

“Suddenly (militants) attacked the dinner gathering...

(then) they broke into the rooms, took some people hostage and they opened fire on some of them,” he told AFP.

Rahimi said the attackers were armed with light weapons and rocket-propelled grenades when they stormed the hotel, a popular venue for weddings, conferences and political gatherings.

Security in Kabul has been ramped up since May 31 when a massive truck bomb killed some 150 people and wounded around 400 -- mostly civilians.

But the resurgent Taliban and Islamic State are both scaling up their assaults on the city, with multiple devastating attacks in recent weeks.

The attack on the Intercontinental was just one of several bloody assaults today.

In a village in the northern province of Balkh, Taliban militants went from house to house in the middle of the night, pulling police from their homes and shooting them dead.

At least 18 officers were killed, deputy police chief Abdul Raziq Qaderi told AFP.

In Herat in the west at least eight civilians were killed when a car hit a Taliban-planted roadside mine, officials there said.

The last major attack on a high-end hotel in Kabul was in March 2014 when four teenage gunmen raided the Serena, killing nine people including AFP journalist Sardar Ahmad.

The overnight siege is not the first time the Intercontinental has been targeted: in 2011 a suicide attack claimed by the Taliban killed 21 people there, including 10 civilians.

Even before the attack was over today, authorities were questioning how the attackers got past the hotel’s security, which was taken over by a private company three weeks ago, said Najib Danish, another interior ministry spokesman.

“We will investigate it,” he said.

A hotel employee told AFP that as he fled the staff living quarters in a building next to the hotel he saw the new security guards running for their lives.

“They didn’t do anything, they didn’t attack. They had no experience,” the man said on condition of anonymity.