This was in spite of global criticism against the practice which many condemned citing both natural and divine laws.
The bill will allow same-sex couples to officially register their marriage from May 24 and comes after a 2017 Constitutional Court ruling that gave the government two years to enact laws protecting the equal rights to marriage of gay couples.
Tens of thousands of gay rights supporters, who turned out in spite of heavy rain, cheered outside the parliament building in central Taipei after lawmakers voted in favour of the bill.
“The first in Asia! Taiwan’s human rights!” prominent gay rights activist Chi Chia-wei shouted from a stage as supporters waved rainbow flags.
The Taiwan Alliance to Promote Civil Partnership Rights welcomed the move, saying it opened a whole new page in history.
“We’ve seen a new phenomenon of gay rights receiving cross-party support,” it said.
“I and my partner will go and register our marriage on May 24 when the household registration office opens. Just can’t wait any longer,” Chien Chih-chieh, the alliance’s secretary general, said.
The Taiwan vote comes as gay rights activists around the world mark the International Day against Homophobia, Transphobia and Biphobia.
The new special law covers issues ranging from inheritance rights, medical rights, adoption of children to monogamy.
It also stipulates penalties for adultery and bigamy.
After the legislation was passed, some lawmakers in favour of the new law called for more social inclusion.
“You will find that the sun still rises in the east and what you worried about same-sex marriage doesn’t exist at all,” Legislator for the ruling Democratic Progressive Party, Yu Mei-nu said.
New Power Party legislator Freddy Lim said that he found that some lawmakers had made comments containing false information about LGBT people.
“We will still need to improve social communication in order to eliminate discrimination against gay people,” Lim said.
aiwan President Tsai Ing-wen said this was a day Taiwan should be proud of.
“The world will see Taiwan as a progressive country because legal protection of love is equally given to everybody,” she said on her Facebook page.
Anti-marriage equality groups expressed their dismay, saying lawmakers ignored a 2018 referendum result showing the people’s will that marriage should be defined as a union between one man and one woman.
“A death knell for our traditional human relationships is ringing,” Coalition for the Happiness of Our Next Generation convener, Yu Hsin-yi told a news conference.
In spite of criticisms globally, Taiwa legislature still went ahead to pass the bill.
There was a backlash against gay marriage movement in morally-conscious Nigeria when some legislators attempted to push the bill to legalise the act in the National Assembly.