NEW YORK (Reuters) - A federal judge on Wednesday voided a White House-backed rule making it easier for doctors, nurses and other healthcare providers to avoid performing abortions and other medical services on religious or moral grounds.

U.S. District Judge Paul Engelmayer in Manhattan said the “conscience” rule was unconstitutionally coercive because it would let the U.S. Department of Health and Human Services (HHS) withhold billions of dollars of funding from hospitals, clinics, universities and other healthcare providers that did not comply.

“Wherever the outermost line where persuasion gives way to coercion lies, the threat to pull all HHS funding here crosses it,” Engelmayer wrote in a 147-page decision.

The judge also said the rule was “arbitrary and capricious,” and conflicted with federal laws governing the obligations of employers to accommodate workers’ religious views, and hospitals to provide emergency treatment to poor patients.

Engelmayer’s decision covered a lawsuit by New York state, New York City and 21 other states and municipalities that are led by Democrats or often lean Democratic, as well as two lawsuits by Planned Parenthood and other healthcare providers. California has filed its own lawsuit challenging the rule.

A spokeswoman for HHS said that agency and the U.S. Department of Justice were reviewing Engelmayer’s decision.

U.S. President Donald Trump, a Republican running for reelection, has made expanding religious liberty a priority, and the conscience rule has drawn support from abortion opponents. The rule was scheduled to take effect on Nov. 22.

FILE PHOTO: Pro-Choice and Pro-Life protesters stand outside of Planned Parenthood as a deadline looms to renew the license of Missouri's sole remaining Planned Parenthood clinic in St. Louis, Missouri, U.S. May 31, 2019. REUTERS/Lawrence Bryant

New York Attorney General Letitia James in a statement said the rule would have encouraged healthcare providers to “openly discriminate” against some patients.

“Health care is a basic right that should never be subject to political games,” James said.

Planned Parenthood also welcomed the decision. “Everyone deserves to access the health care they need,” Acting President Alexis McGill Johnson said. “This rule put patients’ needs last.”

The states and municipalities have said the rule could undermine their ability to provide effective healthcare, and upend their efforts to accommodate workers’ beliefs.

Critics have also said the rule could deprive gay, transgender and other patients of needed healthcare because some providers might deem them less worthy of treatment.

HHS countered that the rule would help enforce conscience protection laws that have been on the books for decades.

Engelmayer, an appointee of former Democratic President Barack Obama, said these protections “recognize and protect undeniably important rights,” but the government’s rulemaking “was sufficiently shot through with glaring legal defects.”

He also chastised HHS for making a “factually untrue” and “demonstrably false” claim that there had been a “significant increase” in complaints about conscience protection violations.

Plaintiffs challenging the rule included Chicago and Washington, D.C., as well as Michigan, Pennsylvania and Wisconsin, states where Trump prevailed in the 2016 presidential election.

The states’ case is New York et al v. U.S. Department of Health and Human Services et al, U.S. District Court, Southern District of New York, No. 19-04676.