The Texas Supreme Court on Friday upheld the state's ban on gender transition treatment for children, allowing the Lone Star State to remain one of at least 25 states, and the largest, with restrictions on such treatment.

The law, which has been in effect since Sept. 1, 2023, prohibits children under the age of 18 from accessing hormone therapy, puberty blockers and gender transition surgery. Children who were already on those medications were required to taper off their use of the drugs. The law includes exemptions for children in early puberty or who have "a medically verifiable genetic disorder of sex development."

The lawsuit that challenged the law argued it harms transgender teenagers who are barred from receiving gender transition treatment recommended by their physicians and parents, according to The Associated Press.

The court, comprised of all Republicans, handed down its ruling in an 8-1 decision.

JUDGE RULES MONTANA LAW DEFINING SEX AS ONLY MALE OR FEMALE IS UNCONSTITUTIONAL

LGBTQ+ activists

The Texas Supreme Court on Friday upheld the state's ban on gender transition treatment for children. (AP)

"We conclude the Legislature made a permissible, rational policy choice to limit the types of available medical procedures for children, particularly in light of the relative nascency of both gender dysphoria and its various modes of treatment and the Legislature's express constitutional authority to regulate the practice of medicine," Justice Rebeca Aizpuru Huddle wrote.

The lone dissenting judge said the court was giving the state's government the ability to "legislate away fundamental parental rights."

"The State's categorical statutory prohibition prevents these parents, and many others, from developing individualized treatment plans for their children in consultation with their physicians, even the children for whom treatment could be lifesaving," Justice Debra Lehrmann wrote. "The law is not only cruel — it is unconstitutional."

A lower court had ruled the law unconstitutional, but it was permitted to take effect during the state Supreme Court's consideration of the case.

Texas Republican Attorney General Ken Paxton tweeted after the ruling that his office "will use every tool at our disposal to ensure that doctors and medical institutions follow the law."

'Protect Trans Youth' protesters

The law prohibits children under the age of 18 from accessing hormone therapy, puberty blockers and gender transition surgery. (Fox News )

The groups who filed the lawsuit criticized the ruling as harmful to transgender children and their families.

"It is impossible to overstate the devastating impact of this ruling on Texas transgender youth and the families that love and support them," Karen Loewy, senior counsel and director of Constitutional Law Practice at Lambda Legal, which was one of the groups that sued the state on behalf of doctors and families, told The Associated Press.

ACLU of Texas' policy and advocacy strategist for LGBTQIA+ rights, Ash Hall, said the government should not "deprive trans youth of the health care that they need to survive and thrive," adding that "Texas politicians’ obsession with attacking trans kids and their families is needlessly cruel."

Gender transition treatment for transgender children is supported by major medical organizations, including the American Medical Association, the American Academy of Pediatrics, the American Psychiatric Association and the Endocrine Society.

BRAGG'S OFFICE FACES BAR COMPLAINT ALLEGING DISCRIMINATION IN 'DIVERSITY' HIRING PRACTICES

Transgender pride flag

The lawsuit that challenged the law argued it harms transgender teenagers who are barred from receiving gender transition treatment recommended by their physicians and parents. (ALLISON DINNER/AFP via Getty Images)

One justice dismissed the medical groups' position as irrelevant to whether the Texas law is constitutional.

"The fact that expert witnesses or influential interest groups like the American Psychiatric Association disagree with the Legislature’s judgment is entirely irrelevant to the constitutional question," Justice James Blacklock wrote in a concurring opinion. "The Texas Constitution authorizes the Legislature to regulate 'practitioners of medicine.'"

CLICK HERE TO GET THE FOX NEWS APP

In a lower court hearing, several doctors who treat transgender children testified that patients could face deteriorating mental health that could potentially lead to suicide if they are denied gender transition treatment.

Texas officials said the law was needed to protect children and pointed to several other restrictions for minors intended to keep them safe, including when it comes to tattoos, alcohol, tobacco and certain over-the-counter drugs.

The Associated Press contributed to this report.