A riot at Perth's controversial Banksia Hill youth detention centre ran into the early hours of the new year as detainees took to roof tops and lit a fire before being returned to their cells.
Western Australian officials said the New Year's Eve disturbance involved 22 detainees, who climbed fences and on top of buildings late on Saturday afternoon.
Two demountable buildings were damaged by fire before the blaze was put out by firefighters, the state's Department of Justice said in a statement.
The detainees progressively came down from the fences during the night and the last was secured in their cell by 12.45am on Sunday, New Year's Day.
No staff or detainees were injured in the incident, while a damage assessment would be carried out during the day, the department said.
Specialist police were deployed to the facility, located near Fremantle, and authorities said there had been no threat to the broader community during the riot.
It comes days after the state's Aboriginal Legal Service went to the Supreme Court seeking a judicial review of continuing lockdowns at the detention centre.
In August, Supreme Court judge Paul Tottle ruled that a teenage boy was unlawfully locked in his cell for up to a day at a time at Banksia Hill.
Justice Tottle found the boy's treatment was not authorised under the Young Offenders Act, despite the facility's problems with inadequate staffing.