ISLAMABAD, Pakistan — A Pakistani court ordered the police to withdraw blasphemy charges against a Christian teenager on Tuesday, lawyers said, bringing an end to a contentious case that had gripped the country and sown fear in its Christian minority population.

The girl, Rimsha Masih, who comes from an impoverished family of sweepers, was arrested in August after Muslim accusers said she had been holding a burned copy of the Noorani Qaida, a religious textbook used to teach the Koran to children.

Relatives and human rights workers have said that the girl, 14, has Down syndrome and should therefore be exempt from the blasphemy laws.

On Tuesday, Justice Iqbal Hameed ur Rahman, who heads the Islamabad High Court, stated in his judgment that there was no evidence for the charges against Ms. Masih. In his 15-page judgment, he urged extreme caution in matters related to blasphemy and criticized the practice of fake blasphemy accusations against non-Muslims.