Restrooms, locker rooms, and showers in public schools nationwide are allowed to remain separated by biological sex for the foreseeable future, a federal judge in Texas has ruled.

U.S. District Judge Reed O’Connor blocked President Barack Obama’s administration’s bathroom mandate on Sunday evening, hours before students in the state woke up for their first day of school.

The judge did not address the underlying policy in question, but argued the Obama administration overstepped its authority when mandating that public schools must open their restrooms, locker rooms, and showers to transgender students based on their gender identity instead of their biological sex.

“This case presents the difficult issue of balancing the protection of students’ rights and that of personal privacy when using school bathrooms, locker rooms, showers, and other intimate facilities, while ensuring that no student is unnecessarily marginalized while attending school,” O’Connor said. “The resolution of this difficult policy issue is not, however, the subject of this order.”

The ruling is part of a challenge brought by Texas and 12 other states against the Obama administration’s bathroom directive, issued on May 13 to public schools nationwide.

In court, the Obama administration argued that it didn’t have to follow standard rulemaking procedures because its guidance was based on previous decisions made by other courts and agencies. O’Connor disagreed, arguing that schools would “jeopardize their federal educational funding by choosing not to comply.”

Although the order could be reversed as the case plays out in court, conservatives are calling it a “huge victory.”

“This is great news out of Texas,” Roger Severino, director of the DeVos Center for Religion and Civil Society at The Heritage Foundation, said. “This judgment stops the administration’s ideologically driven misinterpretation of the law in its tracks and protects the safety and privacy of our children in school showers, lockers, and bathrooms. As with Obama’s earlier lawless actions on immigration policy, the federal courts have once again stepped in to block the administration’s brazen attempt to go around Congress and unilaterally rewrite the law.”

In total, 24 states are challenging the Obama administration’s controversial bathroom mandate in three different lawsuits. These states are suing the departments of Justice and Education over claims that Title IX provides protections for transgender students, thereby requiring schools to allow transgender students into the bathrooms and locker rooms based on their gender identity.

In issuing the ruling, O’Connor, who was appointed by former President George W. Bush, argued the text of Title IX “is not ambiguous” as the administration claimed.

“It cannot be disputed,” O’Connor wrote, that the meaning of the term “sex” in Title IX “meant the biological and anatomical differences between male and female students as determined by their birth.”

Title IX is the federal statute that bans discrimination on the basis of sex in any educational institution that receives government funding.

The issue of whether Title IX applies to gender identity has divided the country, with liberals arguing that access to private facilities in accordance to a student’s gender identity is a basic civil right, while conservatives say opening bathrooms, locker rooms, and showers to students of the opposite biological sex would violate the safety and privacy rights of the rest of the student body.

On Aug. 4, the Supreme Court got involved, issuing a similar ruling as the one handed down in Texas. In that case, the justices allowed a Virginia school system to temporarily keep its bathrooms separated by biological sex until lawyers for the school district file an appeal, despite arguments that doing so would leave a transgender student, Gavin Grimm, isolated from the rest of the student body.

A lower appeals court had sided with Gavin, ruling the school must open its sex-specific facilities to students based on their gender identity.

Matt Sharp, legal counsel at Alliance Defending Freedom, said the Texas ruling—which now runs in direct opposition to the decision handed down by the U.S. District Court in Eastern Virginia—will serve as “a very important precedent” for the Supreme Court, should it decide to take on the issue.

“The big question that has been raised is, does the government have the authority to do this?” Sharp said, adding:

We know the 4th Circuit reached the opposite conclusion in the [Virginia] case, so this sets it up well for the Supreme Court to look at this—we’re now seeing the circuit courts split, with some courts saying there is ambiguity, and other courts saying there is none and Title IX is clear that schools have the authority to set their own rules. I think this is going to be a precedential case in that regard, in that it clearly sets authority that there is not the ambiguity in Title IX that the administration has attempted to manufacture.

The preliminary injunction granted in the Texas case has broader implications than the one issued by the Supreme Court, also prohibiting the Obama administration from “initiating, continuing, or concluding any investigation” based on its interpretation that Title IX applies to gender identity, an issue the Supreme Court did not address.

A group of civil rights organizations that submitted a joint friend-of-the-court brief in favor of the Obama administration’s defense issued a statement that they would “continue to file lawsuits representing transgender students and litigate them to the fullest extent of the law.”

Those groups, which include Lambda Legal, American Civil Liberties Union and ACLU of Texas, National Center for Lesbian Rights, Transgender Law Center, and GLBTQ Legal Advocates & Defenders, instructed schools to continue allowing transgender students into the bathrooms and locker rooms that correspond with their gender identity.

“A ruling by a single judge in one circuit cannot and does not undo the years of clear legal precedent nationwide establishing that transgender students have the right to go to school without being singled out for discrimination,” they said, adding:

This unfortunate and premature ruling may, however, confuse school districts that are simply trying to support their students, including their transgender students. So let us make it clear to those districts: your obligations under the law have not changed, and you are still not only allowed but required to treat transgender students fairly. The scope of this injunction has no effect on the ability of other courts or lawyers representing transgender people to continue to rely on the federal government’s interpretations of Title IX or on prior decisions that have reached similar conclusions about the scope of federal sex discrimination laws.

But in the order, O’Connor, who serves as a judge in the U.S. District Court for the Northern District of Texas, wrote the injunction applies to schools nationwide. If states do not wish to follow the order, he said they can “easily avoid doing so” by passing a state law establishing that gender identity applies to Title IX.

“The court concludes this injunction should apply nationwide,” he wrote. “States that authorize schools to define sex to include gender identity for purposes of providing separate restroom, locker room, showers, and other intimate facilities will not be impacted by it. Those states who do not want to be covered by this injunction can easily avoid doing so by state law.”

The order will remain in effect until the court rules on the merits of the case, unless it is overturned by the 5th U.S. Circuit Court of Appeals, where the Obama administration is expected to file an appeal.