At 7.30pm (AEST) the men left the roof following negotiations with officials from the United Nations High Commission for Refugees (UNHCR), the Immigration Department said.
Activists outside the centre cheered as the last asylum seeker waved and disappeared over the side of the roof and was taken down in a crane.
The men decided to leave just as it started to rain, leaving behind their banner with the words "We need help and freedom" written on it.
The UNHCR had agreed to look more into their cases, refugee advocate Jamal Daoud of the Social Justice Network said.
News that makes sense
Your trusted source for staying up-to-date with the world around you. Get free daily news updates and analysis, straight to your inbox.
"There are no guarantees but the UNHCR has said they will be more involved in their cases."
The protest began after a Fijian man died, amid officially unconfirmed reports of suicide.
Earlier, mental health expert and Australian of the year Patrick McGorry told SBS the self-harm being inflicted by some of the men showed they had become increasingly desperate.

