A federal court has blocked a Dallas suburb's law banning undocumented immigrants from renting.

In the latest ruling on a series of laws targeting immigration that local governments across the nation have passed, the 5th U.S. Circuit Court of Appeals in New Orleans said multiple parts of the ordinance in Farmers Branch are unconstitutional and encroaches on the federal government's authority.

"We conclude that enforcement of the ordinance conflicts with federal law," the court said Monday. The appeals court relied heavily on the U.S. Supreme Court's decision last year that struck down parts of Arizona's immigration law.

The suburb's ordinance would have required all renters to obtain licenses. The city's building inspector would check an immigrant's status and deny licenses to anyone in the country without permission. Landlords who allowed immigrants without permits would have faced fines or revocations of their renters' licenses.

Unless the U.S. Supreme Court decides to step in, Farmers Branch won't be allowed to enforce the ordinance, which has sparked an expensive legal battle. As of late last year, the city — with about 29,000 residents just a few miles north of Dallas — had spent nearly $6 million on legal bills and expenses related to immigration laws, a Farmers Branch spokesman has said.

[Banning immigrants from renting apartments] not only fails to facilitate, but obstructs the goal of bringing potentially removable noncitizens to the attention of the federal authorities.

- 5th U.S. Circuit Court of Appeals

The full appeals court heard arguments last September after a three-judge panel ruled against Farmers Branch in March 2012. The decision to have a full rehearing of a case, known as an en banc hearing, is rare and created speculation that judges wanted to reverse the panel's decision.

In 2012, the three-judge panel wrote, “We conclude that the ordinance’s sole purpose is not to regulate housing but to exclude undocumented aliens, specifically Latinos, from the City of Farmers Branch and that it is an impermissible regulation of immigration.”

Latinos are nearly 50 percent of Farmers Branch, and nearly 80 percent of District 1.

Tensions between Latinos and other residents peaked when the city’s mayor called for banning undocumented immigrants from rentals. 

Farmers Branch Mayor Bill Glancy said late Monday that he hadn't yet seen the opinion and couldn't comment. Kansas Secretary of State Kris Kobach, a well-known advocate for tougher immigration laws who argued the case on Farmers Branch's behalf, did not return a phone message Monday.

William Brewer, the plaintiffs' lead attorney, called the decision "critically important" because the town had "thrust itself into the national debate over immigration."

"This outcome was critically important for those who believe immigration reform must take place at the federal level.”

Being in the United States without legal permission isn't a crime on its own, the court said, and immigrants in the process of deportation are often required to give agents a reliable address. Banning immigrants from renting apartments "not only fails to facilitate, but obstructs the goal of bringing potentially removable noncitizens to the attention of the federal authorities," the court said.

Judges also questioned the process in which a renter or a landlord would be told to appeal a decision under the law in Texas state court. The appeals court said that could open "the door to conflicting state and federal rulings on the question" of whether someone could legally live in America.

Nina Perales, vice president of litigation for Latino civil rights group MALDEF, said the court's ruling sent a strong message that there were "few legal ways" for states and local governments to get involved in immigration.

"It is our sincere hope that (Farmers Branch) will accept the court's ruling, stop wasting the taxpayers' money, and move on to issues of real public concern," Perales said.

Other towns that have fought to enact similar laws have seen mixed success. A federal appeals court ruled against a renters' ordinance in Hazleton, Pa., but a different appeals court last month allowed law passed in the eastern Nebraska city of Fremont to go into effect.

In May, the town made history when it elected its first Hispanic to the City Council.

City Councilwoman Ana Reyes got involved in politics in Farmers Branch after the passage of the law making it illegal to rent to undocumented immigrants.

Her election was in large part the result of the new District 1, created after a federal judge ordered the city to change its election system to single-member district balloting. Reyes, 39, enjoyed a comfortable 2-to-1 lead all through the ballot counting last week, according to The Dallas Morning News.

Reyes, the daughter of Mexican immigrants, beat Bill Capener, co-founder of a group associated with the Tea Party.

Keranews.com said “Her election is significant because Farmers Branch has been an epicenter for policies some consider anti-immigrant.”

The Associated Press contributed to this story.

Follow us on twitter.com/foxnewslatino
Like us at facebook.com/foxnewslatino