At least 27 people have been killed and 227 others wounded in a suicide bombing during Friday prayers at a Shia mosque in Kuwait City claimed by the Islamic State of Iraq and the Levant (ISIL) group.

In a message posted on a Twitter account known to belong to the group, ISIL claimed the blast was the work of a suicide bomber wearing an explosive vest.

Kuwait's interior ministry said the attack targeted the packed Imam Sadiq mosque in the district of Sawaber in the eastern part of the Kuwaiti capital.

Video footage from the scene showed several bodies on the floor of the mosque amid debris and clouds of heavy smoke.

Kuwait's Emir Sabah al-Ahmad al-Sabah visited the mosque, located just a few buildings away from the country's interior ministry. 

He said the bombing violated the sanctity of the Muslim holy month of Ramadan as well as Islamic law forbidding the shedding of the blood of innocents.

"National unity is a protective fence for the security of the nation," the emir said.

'Black terror'

The cabinet announced after an emergency meeting that all security agencies and police have been placed on alert to confront what it called "black terror".

"The cabinet stresses that it will take whatever measures necessary to root out this scourge, and declares a relentless all-out confrontation with these terrorists," it said in a statement.

It also declared Saturday a day of mourning.

The explosion was the first suicide bombing attack on a Shia mosque in the Gulf Arab state.

Kuwait's Minister of Justice, Awqaf and Islamic Affairs Yaqoub al-Sanea, condemned the "terrorist attack" which he said "threatens our security, and aims to fracture the country's unity".

"Kuwait will remain an oasis of security for all groups of Kuwaiti society and all sects. The government is taking many procedures to protect prayers and mosques," al-Sanea told state news agency KUNA.

Shia Muslims comprise between 15 and 30 percent of the predominantly Sunni Muslim state, where members of both communities are known to live side by side with little apparent friction.

Sheikh Mohammed Abdullah al-Mubarak al-Sabah, a Kuwaiti government spokesman, said that despite Kuwait having bolstered security forces with the latest technology, attacks like the one on Friday were very hard to stop.

"We will be investing in metal detectors and the like but even that can be overcome with the use of different types of technologies," he told Al Jazeera.

ISIL targeted Shia mosques in neighbouring Saudi Arabia on two consecutive Fridays in May.

Source: Al Jazeera and agencies