Australian MPs have endorsed the nation's vote to allow same-sex couples to marry - before bursting into song in parliament.
Only four MPs did not back the historic reform, which comes after the country voted overwhelmingly in favour of legalising gay weddings last month.
Onlookers in the packed public gallery hugged, cheered loudly and started applauding and waving their rainbow flags while singing I Am Australian.
"We are one, but we are many," they belted out in unison.
"And from all the lands on earth we come.
"We'll share a dream and sing with one voice.
"I am, you are, we are Australian."
Several politicians on the floor of the chamber joined in. One could be seen wiping away a tear.
"What a day for love, for equality, for respect. Australia has done it," Prime Minister Malcolm Turnbull said.
"This is Australia, fair and diverse, loving and filled with respect."
"Love has won and it's time to pop the bubbly," Greens MP and same-sex marriage supporter Adam Bandt said.
"It's an historic day for Australia today and I think the celebrations around the country when we finally... achieve marriage equality are going to be immense," Janet Rice said before the vote.
The Greens party senator was only able to remain married to her transgender wife of 31 years, Penny Whetton, because Penny remained listed as male on her birth certificate.
Penny Wong, a Labour party senator who has two children with her lesbian partner, said: "I am feeling happy."
Campaigners who had gathered outside the building rejoiced at the news.
The law is expected to be ratified within days, making Australia the 26th nation to legalise same-sex marriage, after some of its states ruled homosexual acts to be illegal until just 20 years ago.
The first legal same-sex unions will be allowed from January.
The existing bill allowed churches and religious organisations to boycott gay weddings without violating Australian anti-discrimination laws.
As the new bill was introduced and debated on Monday, gay MP Tim Wilson, from the ruling Conservative party, fought back tears as he proposed to his partner Ryan Bolger in the country's House of Representatives.
On Tuesday, Austria's supreme court ruled to legalise same-sex marriage in the country from 1 January 2019.