Islamists in Pakistan celebrated their victory over the government after the country's law minister resigned, caving in to fundamentalist protesters who had been demanding his resignation for blasphemy. After Zahid Hamid's resignation, the Tehreek-i-Labaik Ya Rasool Allah party, which was behind a sit-in in Islamabad and protests in other cities and towns across Pakistan, said they were dispersing peacefully under an agreement with the government.

Islamabad Pakistan blasphemy Islamist
An injured protester chants slogans along with others on the flyover as Khadim Hussain Rizvi announces the end of the sit-in Aamir Qureshi/AFP

The development underscored how a small Islamist party was able to pressure the Pakistani government and force it to accept its demands through a protracted standoff that started earlier in November.

The new ultra-religious political party had been protesting against a small change in wording to an electoral law changing a religious oath to a simple declaration, which it said amounted to blasphemy. Insulting Islam's prophet is punishable by death under Pakistani law, and blasphemy accusations stir such emotions that they are difficult to defend against. Even a rumour of blasphemy can spark mob violence, as in the case of a university student beaten to death in April.

Hamid apologised for the omission in the bill, saying it was a clerical error that was later corrected. But the Islamists persisted, taking to the streets and setting up their sit-in at the Faizabad intersection on the edge of the Pakistani capital. The Islamists effectively blocked the country's key highway, the Grand Trunk Road motorway, linking Islamabad with the eastern Punjab province and the northwest, disrupting life and forcing commuters to look for alternate routes.

Islamabad Pakistan blasphemy Islamist
24 November 2017: Activists of the Tehreek-i-Labaik Yah Rasool Allah Pakistan (TLYRAP) religious group chant religious slogans on a blocked flyover bridge during a protest in Islamabad Aamir Qureshi/AFP

Seven people were killed and nearly 200 wounded after riot police descended on the protesters with tear gas and batons on Saturday (25 November). The violent crackdown also triggered solidarity protests by Islamists in other Pakistani cities and towns, leading to what could have been a major political crisis that could have paralysed many urban areas.

Islamabad-based analyst Imtiaz Gul described the outcome of the standoff as a "retreat" by the state. He said Saturday's crackdown was miserably planned and poorly executed. "This operation was launched by thousands of security forces against Islamists and it ended up with the state's retreat," Gul told AP.

Interior Minister Ahsan Iqbal told Justice Shaukat Sadiqui of the Islamabad High Court that the government signed an agreement with the rally organisers to avoid a "civil-war like situation".

Under the deal, the Islamists also agreed not to issue a fatwa, or Muslim edict that could endanger Hamid. The minister's home in eastern Punjab province was twice attacked by Islamists in recent days though he was not there at the time.

Islamabad Pakistan blasphemy Islamist
26 November 2017: Protesters from the Tehreek-i-Labaik Yah Rasool Allah Pakistan (TLYRAP) religious group carry the coffin of a protester who was killed the day before during clashes with police Aamir Qureshi/AFP

At the Faizabad intersection, jubilant Islamists kissed the hand of their leader and party chief, firebrand cleric Khadim Hussain Rizvi, handed out sweets and chanted, "God is Great" and "Prophet, we are here for you." In announcing the deal with the government, Rizvi told supporters they "are immediately ending" the rally. He also thanked the army chief, General Qamar Javed Bajwa, for facilitating the agreement under which Hamid would resign and all detained party activists would be freed – raising questions about the military's role.

Rizvi described the army's role in ending the standoff. "The honourable chief of army staff, General Qamar Javed Bajwa, sent his special envoys to us. We said we do not want to talk to the government; they are our murderers," Rizvi said. "So the general took personal interest and sent his team, saying 'we will become the guarantors, and have your demands fulfilled'. So we said, 'All right. That is what we want.'"

Rizvi asked his followers to pack up but await the return of their detained activists so they could all go back together to the city of Lahore, the party's base. After Rizvi spoke, security forces began removing shipping containers surrounding the sit-in that had bin installed to prevent the protest from spreading deeper into the city.

The government climbdown will be seen as an embarrassment for the ruling Pakistan Muslim League-Nawaz (PML-N) party ahead of elections likely in mid-2018, and underlines the power of religious groups in the nuclear-armed nation of 207 million.

Labaik, one of two new ultra-religious political movements to reach prominence in recent months, has made defending the blasphemy laws a campaign centrepiece with some success. The party won a surprisingly strong 6 percent and 7.6 percent share of votes in two recent by-elections. Islamist parties are unlikely to win a majority in the elections expected next August, but could play a major role.