New Zealand will join a small number of countries that have legalized euthanasia after its citizens voted overwhelmingly in favor of it in a referendum this month.
A second question on the ballot during the Oct. 17 federal election — on legalizing recreational marijuana use — was set to fail, according to preliminary results released on Friday.
Proponents of the cannabis measure expressed frustration with Prime Minister Jacinda Ardern, who had declined to take a position on legalization before the election and revealed only on Friday that she had voted in support of it.
On euthanasia, though, her stance had been clear. Ms. Ardern, who retained the prime ministership with a landslide victory in the federal election, had long expressed support for legalization, and the measure passed with 65 percent of the vote.
The ballot question had bipartisan backing, with her primary opponent in the election, Judith Collins of the center-right National Party, also expressing support. Parliament passed a bill legalizing euthanasia last year, though it needed to be ratified with at least 50 percent support in a referendum to come into effect.
Now, beginning on Nov. 6 of next year, doctors will be able to legally prescribe a lethal dose of medicine to patients suffering from terminal illnesses likely to end their life within six months.
To be eligible, patients must have a significant and ongoing decline in physical ability and experience “unbearable suffering that cannot be eased.” They must voluntarily request the procedure and show that they are able to make an informed decision. Two doctors will have to sign off on the decision.
“What a great day to be a Kiwi,” David Seymour, the lawmaker who had sponsored the act, said to supporters gathered to celebrate the result at Parliament on Friday. He added that the vote had made “New Zealand a kinder, more compassionate, more humane society.”
Euthanasia is legal in five other countries: the Netherlands, Belgium, Luxembourg, Canada and Colombia. Physician-assisted suicide, in which doctors give patients the means to kill themselves, is legal in Switzerland. Some American states and the Australian state of Victoria have legalized forms of assisted dying.
Similarly for marijuana, only a few nations have legalized its recreational use, though several have decriminalized it.
In New Zealand, the ballot measure required voters to approve not just the general principle of legalization, but also specific regulations for the creation of a legal market. Fifty-three percent of voters opposed the measure, and 46 percent voted yes.
Unlike the euthanasia vote, the cannabis referendum was nonbinding, but Justice Minister Andrew Little said on Friday that the government would drop efforts to legalize or decriminalize the drug.
Proponents of legalizing marijuana said they believed that the result could have been changed if Ms. Ardern — who acknowledged during a debate on Sept. 30 that she had used the drug “a long time ago” — had declared her support.
Richard Shaw, a politics professor at Massey University, said the seven-point gap would most likely have “been a whole lot tighter had the P.M. taken the position in public that we now know she took on the ballot herself.”
Especially online, he said, “there’s a certain measure of disaffection, frustration and no small amount of anger that she’s now indicated she has this position and hasn’t clarified why she didn’t take this position before the election.”
New Zealand has historically taken a conservative approach to drugs — in legislation if not always in practice, said Marta Rychert, a drug policy researcher at Massey University. The result, she said, “shows that it’s difficult to garner public support for quite a radical cannabis law reform.”
Dr. Rychert added that the messaging used by proponents, which focused on the health and well-being of New Zealanders, might have been less effective than the economic-focused pitches made by advocates in some American states.
The New Zealand Drug Foundation said the country still must act to reverse a punitive approach to drugs that fell disproportionately on young people and the Indigenous Maori.
“Although a majority of New Zealanders did not vote for the proposed model of legalization, the debate has shown a clear public desire for legal change in some form,” the group’s chairman, Tuari Potiki, said in a statement.
Half a million “special votes” in the referendum still have to be counted, and official results will not be released until Nov. 6. But Mr. Little said the results were “highly unlikely” to be overturned.