Portugal's parliament on Friday passed a law allowing medically assisted dying, putting the Catholic-majority country on course to become the fourth in Europe to legalise euthanasia.
Before coming into force the bill must first be signed into law by President Marcelo Rebelo de Sousa, a staunch Catholic and conservative who was re-elected only last weekend.
The president -- who has yet to make public his position on the issue -- could also either use his veto against the legislation, or refer it to the country's constitutional court for further study.
The bill was adopted in parliament by 136 votes to 78 with four abstentions -- thanks largely to a majority of votes from the ruling Socialist Party which had allowed its MPs to vote freely.
If the president did decide to exercise his veto, a second vote by lawmakers would override it.
Lawmakers had approved proposals aimed at changing the law in February, setting up the vote despite a campaign by the Church for a national referendum on the issue.
Socialist MP Isabel Moreira, a constitutional law expert who helped draft the law, said that it would respect "free choice and every individual's independence".
- 'Right to choose' -
The bill legalises access to assisted suicide for adult patients in a situation of "extreme suffering and irreversible damage".
Several doctors must green-light the procedure, while a psychiatrist would be called in if there are doubts about the patient's ability to make a "free and informed" choice.
Euthanasia is legal in three European countries -- Belgium, The Netherlands and Luxembourg -- while others allow terminally ill people to refuse life-maintaining treatment or to have help to die.
"People deserve the right to be able to choose," retired oncologist Jorge Espirito Santo, who has campaigned for years to make euthanasia legal in Portugal, said before the vote.
He said he was expecting a "historic day".
The Catholic Church, which predominates in Portugal, campaigned against the bill both among its own faithful and those of other denominations.
Its bishops' conference immediately expressed outrage at parliament's approval of the legislation, calling the law an "unprecedented step backwards".
The Portuguese Catholic Doctors' Association called on the president to veto the legislation, saying in a statement that "doctors are not the agents of death!"
In neighbouring Spain, the parliament voted by a wide margin in December to approve a bill that will allow euthanasia under strict conditions, despite fierce opposition from the Catholic church and conservative parties.