The students, who have not been formally charged, will be set free out of "concern for their academic future", the prosecutor's office said in a statement.
The decision came hours after a court ordered the release of the two sons of former president Hosni Mubarak, who was ousted in the 2011 uprising, pending a corruption retrial.
The anti-Mubarak revolt started on January 25, 2011, setting off a tumultuous four years during which his Islamist successor Mohamed Morsi was also unseated.
Signup to our newsletter and follow us on Facebook and Twitter!
A police crackdown on Morsi's Islamist followers after his July 2013 overthrow by the army has left hundreds dead and thousands in prison.
The crackdown has extended to secular regime opponents, some of them leaders of the anti-Mubarak revolt, buttressed by an anti-protest law that came into force in November 2013.
President Abdel Fatah al-Sisi, the former army chief who toppled Morsi, has indicated that some prisoners will be released.
Thursday's announcement was not the first time the prosecutor ordered the release of students, who have increasingly turned campuses into bastions of opposition protests.