Politicians in India passed a bill on Tuesday to end the centuries-old Muslim practice of instant divorce.

Prime Minister Narendra Modi's Hindu-nationalist government supported the new law, even though he faced opposition from rival parties, as well as having failed in a previous attempt to push the bill through in the upper house.

The practice will now carry a sentence of up to three years in prison, as well as a fine. In addition, the legislation will require Muslim men to provide financial support to their spouses, who will obtain custody of any children involved should a couple agree to separate on mutual terms.

"An archaic and medieval practice has finally been confined to the dustbin of history," Modi tweeted.

"Parliament abolishes Triple Talaq and corrects a historical wrong done to Muslim women. This is a victory of gender justice and will further equality in society," he said before concluding, "India rejoices today!"

Instant divorce is when a Muslim man has the ability to terminate his marriage by saying "talaq" three times in succession. The expression, which translates from Arabic as "you are divorced," can be used at any time, and in any form, including telephone, text message or even in a social media post.

The victory for the government was a narrow one, as lawmakers in the Parliament's upper house supported the bill by 99 votes to 84. The more powerful lower house approved the bill last week.

Opposition parties had opposed the bill as they believed it could be misused to harass Muslims. Critics of Modi have previously accused him and his ruling party of demonizing Muslims.

The Supreme Court declared instant divorce as unconstitutional in 2017 and asked the government to make it illegal.

jsi/jm (AFP, AP, Reuters, dpa)

Each evening at 1830 UTC, DW's editors send out a selection of the day's hard news and quality feature journalism. You can sign up to receive it directly here.