Maritime officials received an alert on Saturday that pirates had boarded the timber-carrying ship about 75 miles (120km) from the coast of Yemen.
Ships from three countries diverted to its path. A Chinese team boarded the vessel early on Sunday.
The first hijacking by Somali pirates in five years occurred last month, but this is the second raid since then.
A spokesman for UK Marine Trade Operations (UKMTO) in Dubai, who co-ordinate safe passage for merchant vessels in the Gulf of Aden, said all on board the hijacked ship were safe and heading to an unnamed destination under escort.
The UKMTO said the crew was from Syria, but a statement by India's ministry of defence said they were from the Philippines.
Reports in India said the hijacked ship was travelling between the ports of Kenang in Malaysia and Aden in Yemen.
The UKMTO said navy ships from India, China and Pakistan (the last operating as part of an international combined task force) changed course to approach the Tuvalu-flagged ship soon after the alert was raised.
The crew had locked themselves in the citadel, a safe room inside the ship designed to protect those on board from pirates.
The crew from the Chinese ship boarded the hijacked ship at dawn today, freeing those on board. India's military said it is believed the hijackers fled the ship during the night.
Piracy in the waters off Somalia and Yemen peaked in 2011, with more than 200 attacks.
But after five years with no raids, an oil tanker was seized and held for ransom by Somali pirates in early March and there have been a number of attempted seizures since then.