Iowa's controversial three-day waiting period for abortions has been upheld by a Polk County judge.

Judge Jeffrey Farrell ruled Monday against Planned Parenthood of the Heartland and the American Civil Liberties Union of Iowa, which sued in May to try to block the new law.

Farrell ruled that the law, passed last spring, is legal because it does not place an "undue burden" on a woman's right to abortion.

"The Iowa Act is arguably the strictest mandatory waiting period law in the country, but the only question to the court is whether it complies with the constitutional standard," he wrote. "It does."

However, Planned Parenthood and the American Civil Liberties Union immediately filed a notice that they plan to appeal to the Iowa Supreme Court. The matter will remain on hold while that appeal is considered.

Judge Farrell noted that 27 states have implemented waiting periods for abortion, ranging from 18 to 72 hours. Many have sparked legal challenges, with mixed results.

The Iowa Supreme Court previously considered the abortion issue in 2015, when it rejected an Iowa Board of Medicine rule that effectively would have barred Planned Parenthood physicians from using telemedicine to dispense abortion pills to women in remote clinics. In that case, Farrell had upheld the rule, but was unanimously overruled by the justices.

In the new case, Farrell wrote that unlike that Board of Medicine rule, Iowa's waiting-period law does not aim to protect women's health. Instead, its aim is to give women a chance to think over their decision before proceeding with an abortion, he wrote.

"The undue burden standard has been criticized, but it fairly balances the two competing interests of a woman’s right to choose an abortion versus the public’s interest in potential life," he wrote. "The evidence at trial focused on the hardships women face when dealing with an unwanted pregnancy, but the public’s interest in potential life is an interest that cannot be denied under the law. Both of these interests are important."

The judge appeared to agree with Planned Parenthood that Iowa's waiting period would not lead many women to change their minds about having abortions.

"The women in this group have thought hard about the decision by the time they make the appointment to have an abortion," he wrote.

A spokeswoman for Planned Parenthood declined comment, beyond saying the organization was considering all of its options.

Prominent abortion opponent Jenifer Bowen said she wasn't surprised by Farrell's ruling, especially given his previous ruling in the telemedicine-abortion case. She said she was heartened to hear he concluded the new state law had passed the "undue burden" test of whether an abortion restriction is constitutional.

Bowen said she was unsure how likely the law's chances would be on appeal. "We don't have a Supreme Court in Iowa that has tended to rule toward life in recent decisions," she said. However, she added, "I want to give them the benefit of the doubt that they will hear the case out."

Besides the 72-hour waiting period, the new law would require that women be given the option to view an ultrasound and receive materials about risks associated with abortion. In addition, the legislation would impose a ban on most Iowa abortions after 20 weeks, although that provision was not a focus of the lawsuit.

Planned Parenthood, the state's largest abortion provider, had contended that some sections of the law violate the Iowa Constitution, citing a lack of due process and equal-protection rights.

In a statement Monday evening, Planned Parenthood leaders said they would continue to seek a reversal of the "malicious, politically motivated, anti-woman legislation."

In addition to a waiting period, the law effectively would require women to make two trips to a doctor to obtain an abortion, the organization said. "This law would force women to have an abortion later in pregnancy and risk their health solely for political – not medical – reasons," the statement said.

The defendants in the case are Gov. Kim Reynolds, a Republican, and the Iowa Board of Medicine.

Planned Parenthood officials argued that people most affected by the legislation would include low-income women, victims of domestic violence or sexual assault, as well as women with pregnancies with severe fetal anomalies and those who do not fall under narrow emergency exceptions in the legislation.

The Iowa House amended the legislation to strip out criminal penalties, though the law would allow women to pursue civil cases against providers who perform illegal abortions.

It also allows physicians to be disciplined by the Iowa Board of Medicine if they're found to be in violation of the law.

The anti-abortion legislation was passed earlier this year with strong support from Republican majorities in the Iowa House and Senate. It has been described as one of the most restrictive abortion laws in the nation.

Former Gov. Terry Branstad, a Republican, signed the legislation in May shortly before he became U.S. ambassador to China, calling it one of the "most pro-life" bills that had come across his desk in recent years.

The new law includes a provision allowing an abortion after 20 weeks if doctors determine it's necessary to preserve the life or health of the mother.

However, it does not include exemptions for pregnancies resulting from rape or incest, or for pregnancies in which a genetic anomaly makes life after birth impossible.

During legislative debate on the bill, some Republican legislators had expressed hopes that anti-abortion legislation might go further and block even more abortions. They introduced legislation declaring that life begins at conception, effectively outlawing all abortions.

The House also briefly considered advancing a "heartbeat" bill, which would block most abortions after a fetal heartbeat can be detected, often as early as six weeks into a pregnancy.

But more restrictive legislation in other states has not survived legal challenges, causing some Republicans to push back. They contended a better way to advance their cause would be to focus on changes that could have an immediate effect.

Seventeen states have enacted 20-week abortion bans.

Supporters of the abortion restrictions included the Iowa Catholic Conference and the Iowa Right to Life Committee.

Other opponents of the bill included the Family Planning Council of Iowa, the League of Women Voters of Iowa, the Interfaith Alliance of Iowa Action Fund, and the Iowa Coalition Against Sexual Assault.