The suspect, from Zagazig, 60 kilometres (40 miles) north of Cairo, stands accused of killing his victim, identified only by her first name Salma, by "repeatedly stabbing her with a knife", a prosecution statement said.
There was widespread outrage on social media over the latest killing but some users suggested the victim was at fault for befriending a male student.
"Salma was murdered simply for being born a woman in a misogynous society," one user said.
"So long as there are sympathizers out there who make excuses for the perpetrators of these crimes, they will continue," said another in response to a user who criticized the victim.
The latest killing revived memories of the June murder of student Nayera Ashraf, stabbed to death in front of her university in Mansoura, 150 kilometers north of Cairo.
In March, a teenager was sentenced to five years in prison over the suicide of a schoolgirl after images of her were shared online.
Conservative interpretations of Islam in Egypt have contributed to severely limiting women's rights.
Women report being targeted by routine violence with little legal redress.
Nearly eight million Egyptian women were victims of violence committed by their partners or relatives, or by strangers in public spaces, according to a United Nations survey conducted in 2015.
High-profile femicides have triggered widespread anger in Egypt in recent months.