A mob attacked a man and beat him brutally inside a mosque in Chitral after he was accused of uttering blasphemous remarks following Friday prayers.

The man, who is yet to be identified, is alleged to have pushed the imam of the mosque to allow him to speak after jummah prayers, a local present at the site told DawnNews. Eyewitnesses claim the man then uttered 'blasphemous remarks' amidst the prayer gathering.

As worshippers started beating the man, the mosque's imam, fearing for the man's life, handed him over to the police.

Police took the man to the local police station for his protection. They said they were trying to ascertain the man's mental health.

A First Information Report (FIR) has been filed against the man over charges of blasphemy and terrorism, Deputy Commissioner Chitral Shahab Yousafzai told DawnNews.

"The situation is under control now," Yousafzai said, adding that police is investigating the case.

"At the moment, I am not in a position to comment on the mental health of the man," Yousafzai said. “A team of doctors will file a detail report about his mental health,” he said.

Mob reaches police station

Soon after the accused was shifted, the mob attacked and broke into the police station amid aerial firing and heavy tear gas shelling from the police. The firing resulted in power outages nearby as transmission lines were damaged by bullets.

The situation remained volatile, police said, while they attempted to cool the mob down and restore peace in the area.

The Frontier Constabulary also reached the police station to assist with maintaining law and order, a police official said, adding that "3,000 to 4,000 people" were still present outside the police station.

The district administration has called a meeting of the local ulema and officials to discuss the incident.

'Rule of law should prevail'

The incident comes days after a vigilante mob lynched 23-year-old Mardan university student Mashal Khan over allegations of blasphemy.

The brutal lynching, which occurred inside the premises of Abdul Wali Khan University, Mardan, had invited unanimous condemnation from the National Assembly.

Lawmakers and religious scholars alike repeatedly stressed after the Mashal case that mobs cannot be allowed to take the law into their own hands.

The also stressed that even if someone was accused of blasphemy, police should be allowed to follow due process and the case should be decided only in a court of law.

Pakistan Tehreek-i-Insaf chief Imran Khan had been particularly critical of the incident, describing it as "the law of the jungle".

Prime Minister Nawaz Sharif issued a strongly-worded condemnation of the incident two days later.

"The state will never tolerate those who take the law in their own hands," the premier had warned.

An investigation into Mashal’s murder is on-going and arrests are being made.