New Zealand this week became one of the first countries to offer paid leave to workers who have experienced miscarriages, a move that lawmakers hailed as an example to other nations as well as a bid to destigmatize the experience that thousands of women in the country go through every year.

The country’s parliament unanimously approved legislation Wednesday that would offer three days of bereavement leave from work to mothers and their partners if they go through a miscarriage. While some companies have such policies in place, some women have otherwise taken sick leave after experiencing the loss of a pregnancy.

“The grief that comes with miscarriage is not a sickness. It is a loss,” said Ginny Andersen, a member of Prime Minister Jacinda Ardern’s Labour Party who introduced the bill to parliament. “That loss takes time — time to recover physically and time to recover mentally, time to recover with a partner.”

Other countries with legislation of this kind include the Philippines and India, where women are entitled to six weeks of paid leave if they miscarry. But the law applies only to those who work at a company with 10 people or more, according to Quartz, meaning just a small portion of the population benefits, since so many women work in India’s informal job market.

New Zealand lawmakers said they hoped the legislation, which also applies to lost pregnancies through adoptions and surrogacies but does not apply to abortions, would pave the way for other countries to follow suit.

“I can only hope that while we may be one of the first, we will not be one of the last, and that other countries will also begin to legislate for a compassionate and fair leave system that recognizes the pain and the grief that comes from miscarriage and stillbirth,” Andersen said.

Previously there was no support in New Zealand for women who lost a baby less than 20 weeks into their pregnancy.

“You were expected to treat it like it was not even a cold. There was no provision for that major life event,” said Vicki Culling, a Wellington-based educator who works with families coping with the loss of a baby.

She said the legislation is “fantastic,” but she is calling for even better support for bereaved parents, who often show up in a hospital emergency department, where they typically get a medical response to their loss along the lines of: “At least you know you can get pregnant.”

“Societally, we tend to measure and say, ‘Oh well, early loss is not as bad as a full-term stillbirth,’ ” said Culling, whose first daughter was stillborn — an experience that led her to set up a service to help support bereaved parents and educate health professionals. “There’s no hierarchy of loss. It’s sad for everyone.”

Other countries have less-generous policies in place for miscarriages and stillborn births. In Australia, women can take unpaid leave if they lose a baby after at least 12 weeks of pregnancy. In Britain, women are entitled to paid leave if they have a miscarriage or stillborn birth after 24 weeks. The United States has no laws addressing miscarriages or stillborn births and the workplace.

In other parts of the world, miscarriages can put women in jail. More than a dozen women are in prison in El Salvador, charged with aggravated homicide under the country’s total ban on abortion, after suffering what they say were obstetric emergencies. Similar cases have permeated in Mexico, Argentina and the United States.

According to the Mayo Clinic, up to one in five pregnancies can end in a miscarriage. Many women, however, can feel ashamed and isolated when it happens to them, unable to share the statistically common experience with their peers or loved ones.

“I hope that this bill will go some way in allowing women to feel more comfortable about talking about miscarriage and that they feel comfortable reaching out for support and for help in what is a huge physical and emotional loss,” Andersen said.

Her words resonated with other women in New Zealand.

“I think it’s amazing that politicians are speaking about such private issues on such a public stage,” Kathryn van Beek, a Dunedin writer who campaigned for the legislation after losing a baby in 2016, wrote in a blog post after the law was passed. “Their actions will help break down some of the taboos around miscarriage and baby loss.”

The bill’s passage is the latest in a string of policy changes that have addressed women’s rights under Ardern’s time in office. Last year, the country decriminalized abortion and passed a law addressing pay inequity.

Correction: A previous version of this article incorrectly excluded the Philippines from the short list of countries with paid leave for miscarriages. This version has been corrected.