Australia has been urged to take a more humane approach to asylum seekers but not dismiss those pushing back against refugees as bigots or racists.
The United Nations' leading voice on human rights has called on Australian politicians to save the the medevac bill, calling it a "small step of progress" in an often "harmful" immigration regime.
On Tuesday, UN High Commissioner for Human Rights Michelle Bachelet used an address in Sydney to criticise the Morrison government's treatment of asylum seekers both onshore and offshore.
"Mandatory detention is a mainstay of Australia's migration and asylum system," she told the Australian Human Rights Commission's Free and Equal conference.
"The people it affects have largely committed no crime; many of them are in very vulnerable situations, and some are children, yet they are subjected to prolonged, indefinite and effectively unreviewable confinement.
"This includes those who remain in the offshore centres such as Nauru and Manus Island. We have a wealth of evidence to demonstrate the harmful effect this has on their mental and physical well-being."
Ms Bachelet called on MPs to stand up to Prime Minister Scott Morrison and save legislation that gives doctors more say in emergency medical transfers of asylum seekers from Papua New Guinea and Nauru to Australia.
The Morrison government is trying to repeal the "medevac bill" with the process underway in Parliament.
"The so-called medevac law that came into effect in March this year is another example of the practical improvements that can be made to the asylum system to uphold international human rights obligations and mitigate the harmful effects of detention," she said.
"I am concerned that the plans to repeal this law may mean more and costly court battles, with lives being put at risk. I appeal to members of parliament not to reverse these small steps of progress that have been made."
But she also said there needs be more understanding on all sides of the immigration debate.
"Rather than labelling people who favour refugee pushbacks as bigots and racists, we need to listen and recognise the fear, anxiety, insecurity or other factors that may be behind such attitudes."
Ms Bachelet's speech came less than a week after Mr Morrison decried "negative globalism" and unaccountable internationalist bureaucracies.
Later pressed for specific examples, the prime minister said there had been plenty of advice about what Australia should or should not do on border protection.
Throughout the year, the government has said the medevac bill is one step towards a "soft on borders" approach.
In her wide-ranging speech, Ms Bachelet discussed an array of human rights concerns she had about Australia.
She said Australia's efforts at gender equality were "better than many other countries, but still women continue to face many barriers, including unequal pay, workplace discrimination and pervasive sexual harassment".
"I have heard for a long time about the exceptionally misogynistic approach to women politicians by many men in Australian political life, and elsewhere in society," she said.
Ms Bachelet also touched on Australia's Indigenous relations.
"I was shocked to learn that the age of criminal responsibility in Australia is only 10 years old ... Some 600 children under the age of 14 are locked away in youth jails every year across this country. Aboriginal and Torres Strait Islander children make up almost 70 per cent of them," she said.
"A treaty with Aboriginal and Torres Strait Islander people, and constitutional recognition of the First Nation people's voice in national affairs would be historic steps."
Ms Bachelet fled her native Chile during the reign of dictator Augusto Pinochet in the 1970s and sought refuge in Australia.
She and other Chilean advocates brought Australia's attention to human rights abuses suffered by many under Pinochet.
Not only did Ms Bachelet return to Chile, but she went on to become the country's first female president, serving from 2006-2010 and again 2014-2018.
She briefly reflected on her time in Australia during her Tuesday address.
"I am pleased to return to this country that first gave me refuge ... I recall the solidarity, warmth and generosity Australians showed to me at that time, although I cannot help wonder whether I would experience the same as a refugee today."
Additional reporting: AAP