Judge Virginia A. Phillips, a judge of the U.S. District Court for the Central District of California, has permanently barred the Obama administration from enforcing the "don't ask, don't tell" policy nationwide, NPR's Carrie Johnson reports.
Phillips said it violates the fundamental rights of servicemen and servicewomen under the constitution.
The judge said the Pentagon must suspend any active investigation or military discharge proceeding.
The lawsuit was filed by the Log Cabin Republicans. They asked the judge to impose a permanent injunction on "don't ask, don't tell," but the federal government said that would be too broad and asked for a delay.
Judge Phillips rejected the government's request. She said that gay service members would face irreparable harm if the policy stayed in place.
According to Johnson, the Obama administration has the option to appeal.