The hostages were freed late on Tuesday night, Iraqiya said.
The forces found the hostages when they raided several houses in Baghdad, it quoted an interior ministry spokesman as saying in the early hours of Wednesday.
Intial reports had said that more than a 100 people were kidnapped after men in police uniforms raided the ministry on Tuesday morning.
The Iraqi government later said that about 50 people had been seized in the mass-kidnapping.
Some witnesses said the hostages were driven in trucks towards the mainly Shia area of Sadr city.
It is unclear if all the hostages have been freed. Some reports have said that up to 20 people may still be missing.
Academics are increasingly being singled out in sectarian violence, and thousands of professors and researchers have fled from the country.
A university dean and a Sunni geologist have been murdered in recent weeks. At least 155 education workers have been killed since the war began.
The security forces have been accused of taking part in, or turning a blind eye to several previous mass kidnappings which are believed to have been carried out by sectarian groups.
The Sunni minority have blamed many of the kidnappings on armed groups from the now dominant Shia parties, who control the interior ministry.
The higher education ministry is headed by a member of the Sunni Arab political bloc.