Natasha Habib, a 16-year-old student of class 10, shot herself with a pistol during an examination yesterday.
She was a student of the Government Girls Centennial Model High School in Haripur, located about 60 km from Islamabad.
Officials at a local hospital said the girl's body had several bruises.
A message written on her right arm asked her mother to forgive her and claimed a man named Asad had harassed her and made her life miserable.
Police rang the number but found it was switched off, officials said. A teacher at the school told police that other students had said that Habib initially pulled out a bottle of acid and tried to drink it.
The other girls snatched the bottle from her hand. Habib then took out a pistol from her bag and shot herself, the teacher said.