Riyadh: An alleged new affiliate of the Islamic State group in Saudi Arabia has claimed responsibility for an attack that targeted a mosque used by police special forces in the kingdom's south-west on Thursday, killing 15 people.

It was one of the deadliest attacks in years against Saudi security forces that battled a wave of al-Qaeda attacks about a decade ago and which have come under sporadic attacks in recent weeks in the capital, Riyadh, by militants purportedly linked to the Islamic State group.

The claim by the so-called Hijaz Province of the Islamic State appeared hours after the attack in the city of Abha, close to Saudi Arabia's southern border with war-torn Yemen. It was carried on IS-affiliated Twitter accounts and was also reported by the SITE Intelligence Group, which tracks militant messages.

The statement says an IS suicide bomber targeted a "monument of the apostate". It was the first claim by the purportedly new IS branch, which has not been heard of previously. The "Hijaz" in its name is a reference to the historic western part of Saudi Arabia that is home to Islam's holiest sites of Mecca and Medina.