An angry mob of 80 Muslims has confronted a Christian boy, demanding he is hanged.
The mob also threatened to burn his family to death for a Facebook post they claim insulted Islam.
The case is just the latest of rising persecution of Christians in Pakistan, a Muslim-majority country.
Nabeel Masih, 16, from Punjab, who faces the death penalty for posting a picture of the Kaaba religious pilgrimage site in Mecca, had to be rushed under protective guard from court, the Express reports.
The "insulting and sacrilegious" image is alleged to have featured a pig's head.
The mob has even threatened his defence team for taking the case. Masih's lawyer Aneeqa Maria said it was becoming increasingly tense.
The team said: "There were about 80 people of different age groups including students that were present in the premises only for Nabeel's hearing and each of them was continuously calling on the phone for other people to come. Even the lawyers were threatened."
Mari said she was told by a prosecution lawyer: "Do you have any idea in what cases are you appearing as a counsel, it's a blasphemy case and this man has blasphemed against Islam and you should know that Pakistan is an Islamic state, we are all Muslims, and these are Muslim courts so you should not defend such a criminal.
"You people come from Lahore to pursue this case here we have unlimited people whom you cannot face, so you better watch yourself and stay away."
Masih is in custody and his family has fled their home. The date of the next hearing has not yet been set.
The British Pakistani Christian Association said: "Apparently to rub salt in the wounds of the poor victim Nabeel Masih, the local constabulary have been hard at work concocting a series of other cyber-crimes that they believe Nabeel has committed.
"The investigation is taking longer then expected so they have asked for more time to complete their supplementary report. In other words just in case Nabeel escapes a blasphemy charge due to international outrage, the police will find another way to detain Nabeel against his liberty."