The clinics argued that the law barring them as Medicaid providers violated their rights to free association and equal protection under the law.
In the end, Texas created a new women's healthcare program funded entirely with state dollars.
Monday's ruling will allow the state to bar Planned Parenthood from that program, which is scheduled to launch on Tuesday, Jan. 1.
Officials in Texas cheered the decision from Visiting State District Judge Gary Herger.
"We are pleased that the court rejected Planned Parenthood's latest attempt to skirt state law," said a spokeswoman for Texas Attorney General Greg Abbott.
"The Texas attorney general's office will continue to defend the Texas legislature's decision to prohibit abortion providers and their affiliates from receiving taxpayer dollars through the Women's Health Program," the spokeswoman said.
Planned Parenthood officials said the decision will bar poor women from access to a trusted healthcare provider.
"For sixty years this program has provided health screenings to women who otherwise would not have it, it has been a great federal-state partnership, it has saved taxpayer dollars, and Planned Parenthood has been a key part of this program from Day One," said Sarah Wheat, interim co-CEO of Planned Parenthood of Central Texas.
The Women's Health Program provides care for 110,000 women in Texas and 48,000 go to Planned Parenthood, according to The Associated Press.