A Pakistani mob burned down several homes belonging to the minority Ahmadi sect in the country's east, killing a woman and her two granddaughters in riots following rumours about blasphemous postings on Facebook.

The rioting in the city of Gujranwala erupted late on Sunday (local time) after claims that an Ahmadi had posted a blasphemous photo of the Kaaba - the cube-shaped structure in the Grand Mosque in Mecca, Saudi Arabia, which observant Muslims around the world face in prayer five times a day, police official Zeeshan Siddiqi said. He said the photo allegedly contained nudity.

The victims died of suffocation, Siddiqi said, adding that another woman miscarried during the riots and was in hospital.

Like other Pakistani minorities such as Christians, Hindu and Sikhs, Ahmadis have long been persecuted by Islamic extremists. They follow the self-proclaimed prophet Ghulam Ahmad and consider themselves Muslims, though Pakistani law forbids them from identifying themselves as Muslims.

In May, two Ahmadis, including a visiting American cardiologist of Pakistani origin, were shot and killed.

Siddiqi said the Gujranwala incident started with the son of a local prayer leader who said an Ahmadi boy had posted the Kaaba photo on Facebook. A group of residents went to the boy's house, a brawl erupted and a bullet was fired, wounding the prayer leader's son.

Blasphemy is a crime in Pakistan and those convicted of it can get life sentences or the death penalty. However, crowds or individuals often take the law into their own hands.

This climate of fear makes it difficult to prosecute blasphemy cases. Judges often hold court sessions inside jails because they are considered the only safe places for the proceedings. Witnesses are reluctant to testify in defence of people accused of blasphemy, fearing they could also be targeted.

In May, gunmen in the city of Multan killed a lawyer and a human rights activist who was representing a university professor on trial for blasphemy. The professor is also accused of posting blasphemous material at Facebook.

Blasphemy cases, which have been on the rise in Pakistan, are also often used to settle personal scores.