ATLANTA — Should Maria Palacios, a Mexican-born Georgia resident who moved to the state as a child and became an American citizen in June 2017, be allowed to run for the State House of Representatives?

She has been fighting for that right since she was thrown off the ballot in May, first by an administrative law judge, then by the Georgia secretary of state, Brian Kemp. Her legal battle comes against the backdrop of a state whose population is rapidly changing, a governor’s race with illegal immigration as a white-hot issue among conservatives, and a nationwide fear among liberals that their opponents are rigging the system to keep people of color out of the voting booths — and out of office.

Ms. Palacios, 28, hit another roadblock in an Atlanta courtroom on Wednesday, when a Superior Court judge agreed with Mr. Kemp that she was ineligible to appear on the November ballot as the Democratic candidate in the 29th District.

Mr. Kemp is running for governor, and facing a runoff on July 24 for the Republican nomination. He has attracted national attention — and a boost in his poll numbers — with ads that showed him brandishing a shotgun and boasting that he might use his pickup truck to round up “criminal” illegal immigrants and “take ’em home myself.”

In Georgia, Mr. Kemp has infuriated liberals by supporting a voter ID law and by questioning the validity of thousands of voter registrations collected by a group founded by Stacey Abrams, the former minority leader in the State House, who won the Democratic primary for governor.

After the court hearing on Wednesday, Ms. Palacios’s lawyer, Sean J. Young, the legal director for the American Civil Liberties Union in Georgia, said she would appeal to the Georgia Supreme Court. “The court clearly did not comply with the Constitution of Georgia today,” Mr. Young said.

The terse ruling from the bench by Judge Craig L. Schwall Sr. appeared to see merit only in Mr. Kemp’s side of the argument. A critical provision of the state Constitution says that to be eligible to run, a candidate must have been a citizen of Georgia for two years. And Mr. Kemp wrote in his decision that “it is necessary to be a U.S. citizen in order to be a ‘citizen of the state.’”

Ms. Palacios says she has lived in Gainesville, Ga., a poultry-producing hub at the heart of her North Georgia district, since 1994, when she was 4 years old. Her parents had entered the country on migrant farmworker visas and brought her across the border without authorization. But she became a legal Georgia resident in 2009, and her lawyers say there is ample case law to support their claim that that qualifies as state citizenship and should make her eligible to run.

The judge was not persuaded. “It seems to me that in order to be citizen, not a resident, of Georgia, you have to be a United States citizen,” he said.

Keeping Ms. Palacios off the ballot would leave the Republican incumbent, Matt Dubnik, running unopposed, in a year when Democrats could pick up some seats in the State House, though probably not seize the majority from Republicans.

The 29th is the kind of district that could give Republicans problems in the long term. The demographics of Gainesville and the surrounding area in Hall County have changed immensely in recent years, as Hispanic workers have flocked to the area to work in the chicken plants and on construction crews in and around Atlanta. The city of Gainesville, for instance, was less than 8 percent Hispanic in 1990, but is about 42 percent today. Though the original arrivals were often undocumented immigrants, many of their children — like Ms. Palacios — are now citizens and eligible to vote.

Outside the courtroom, Ms. Palacios, a soft-spoken P.T.A. president who works for an organization of Latino elected officials, said she was saddened by the ruling. “I’d love the opportunity to represent my community,” she said.

Mr. Young has said in legal filings and interviews that when the Georgia Constitution was drafted in the late 19th century, the phrase “citizen of the state” was taken to mean a resident, “without connotation of United States citizenship.”

And the clause setting out the qualifications for House candidates, Mr. Young said, “already contemplates someone first being a state citizen, and then becoming a U.S. citizen, which is exactly what Maria has done.”

Some of Ms. Palacios’s supporters make a different argument, based less on law than on their concerns about concerted efforts to keep minority candidates out of public office.

A 2014 report by New American Leaders, a nonprofit group, found that Latinos and Asian-Americans represented more than 22 percent of the population, but held fewer than 2 percent of the 500,000 elected positions in the country, from school boards to Congress.

Mr. Trump’s election was preceded by a flurry of federal court rulings that dismantled some of the more onerous voting and election restrictions that had been imposed in states like North Carolina, Wisconsin and Texas. But in the 19 months since he took office, Republican-dominated legislatures have been working to impose new restrictions in many states.

“In recent years, we have seen a surge in candidates from underrepresented communities running for office — women, Latinos, African-Americans and many Muslims,” said Edward Ahmed Mitchell, executive director of the Georgia chapter of the Council on American-Islamic Relations, before the hearing on Wednesday. “This is a positive thing for our state and a positive thing for our nation. Sadly, we’ve also seen a backlash against those candidates — hate speech, death threats and, in Georgia, an attempt to twist the law to block a candidate from running.

“That is exactly what has happened to Maria Palacios,” he added.

Mr. Kemp’s office did not respond to a message seeking comment.

Mr. Young said he would ask the State Supreme Court to resolve the case before Labor Day, because absentee ballots must be mailed by Sept. 18. Georgia does not allow write-in voting.

Michael Wines contributed reporting.

A version of this article appears in print on , on Page A11 of the New York edition with the headline: Narrow Reading of State Citizenship Keeps Georgia Woman Off a Ballot. Order Reprints | Today’s Paper | Subscribe