Education Secretary Betsy DeVos. (Jabin Botsford/The Washington Post)

A federal court ruled this week that an Obama-era regulation designed to ensure children of color are not disproportionately punished or sent to special-education classrooms must take effect immediately.

Published in the final days of the Obama administration, the rules were supposed to have taken effect in 2018. But Education Secretary Betsy DeVos moved in the summer to delay them for two years. The decision, issued Thursday, is a rebuke of her action.

Under the regulation, states will face tighter rules about how they count children in special education. Those calculations may tip more states over a threshold that requires them to create a plan to ensure students of color are not being disproportionately targeted.

Rep. Robert C. “Bobby” Scott (D-Va.), chairman of the House Education Committee, called the decision from U.S. District Judge Tanya S. Chutkan a “major victory” for students and parents.

“By forcing the Trump administration to implement the rule, the court’s ruling will put us back on a track toward reversing systemic racial discrimination in education,” he said. “The court’s ruling confirms our suspicion that the Education Department’s delay of the . . . rule had no basis in evidence or facts.”

Education Department spokeswoman Liz Hill said, “We are reviewing the ruling and evaluating our options.”

The decision stemmed from a lawsuit filed by the Council of Parent Attorneys and Advocates, an advocacy group for children with disabilities.

The ruling found that the department violated the Administrative Procedures Act by failing to provide a “reasoned explanation” for its delay and failure to consider the costs of the postponement. It lifts the two-year delay.

The Obama-era rule changed how states must implement the Individuals with Disabilities Education Act, which governs special education in schools throughout the nation.

Congress, responding to concerns that students of color were overrepresented in special education, requires that school systems collect data on the demographics and treatment of special-education students. This data can help determine whether African American special-education students are more likely to be removed from mainstream classrooms, for instance, or whether Hispanic ­special-education students face harsher discipline.

If states identified problematic disparities, they could set aside federal special-education funds to help schools improve.

But the Obama administration became concerned that states had too much leeway to determine when a problem exists. A 2013 report from the Government Accountability Office found that states identified just 2 percent of districts nationwide as having problems with disparities. Advocates suspect the problem is far more widespread.

So in the closing days of the Obama administration, the department issued what is known as the “significant disproportionality rule,” which more clearly defines how states should identify problematic school systems.

The Trump administration complained that the rule could lead to quotas, but the court said that reasoning was flawed.

Moriah Balingit contributed to this report.