MIAMI — It felt like 100 degrees on a recent Saturday when Carlos A. Gimenez, the Republican candidate in Florida’s most competitive congressional race, stood on a busy street corner in the Miami suburbs with a gaggle of masked relatives and campaign volunteers, waving signs at the honking cars.
The driver of a souped-up Toyota Corolla revved his engine. A street vendor took advantage of the political gawkers to step in between lanes of traffic, selling fresh guavas for $5 a bag. On the opposite corner, a homeless man seized the moment and held up a piece of cardboard where he had scrawled, “Biden Harris.”
Many, if not most, people recognized Mr. Gimenez, the mayor of Miami-Dade County. But the few who came up to him did not want to talk about Congress. They had more pressing matters: When would traffic engineers synchronize signals to ease rush-hour congestion? Was he able to license street vendors so they could avoid getting picked up by the police?
In that distinction between mayor and congressman lies one of the biggest challenges for Republicans hoping to win back Florida’s 26th Congressional District.
Their unusually high-profile candidate enjoys widespread name recognition that most politicians can only dream of. “I told my husband, ‘Oh my God, that looks like Mr. Gimenez!’” Margarita Rodríguez, 67, squealed when the mayor knocked on her door while campaigning in October.
But making the leap from local to federal office — and from nonpartisan to partisan — can be difficult, especially when the candidate has to spend an election year dealing with a pandemic. Mr. Gimenez has been unable to match the fund-raising by Representative Debbie Mucarsel-Powell, the Democratic incumbent, allowing her to bolster her standing in the race.
So a contest that until not long ago was considered a tossup in one of the few districts in the country where a Republican might unseat a Democrat is now seen by political analysts as one that leans slightly Democratic, a reflection of Republicans’ national struggles when it comes to trying to pick up House seats.
“We haven’t had a lot of races move back and forth like that,” said Nathan L. Gonzales, the editor of the Inside Elections newsletter, which analyzes congressional races.
The evolution of the race suggests that Ms. Mucarsel-Powell, a freshman who two years ago ousted former Representative Carlos Curbelo, has had the same success as other Democrats across the country in tying her opponent to President Trump and cementing support from suburban woman and voters worried about immigration and health care. Born in Ecuador, she is the first member of Congress who immigrated from South America.
At a campaign appearance outside the local nurses’ union, Ms. Mucarsel-Powell praised the hospital workers in scrubs, hairnets and masks for their dedication during the coronavirus pandemic. Eliana Ramos, a social worker who immigrated from Cuba, approached the congresswoman and asked for a photograph.
“You’re an inspiration to me,” Ms. Ramos told her in Spanish.
“Don’t make me cry!” Ms. Mucarsel-Powell responded.
The 26th District, which goes from the western Miami suburbs to Key West, is also a good microcosm by which to gauge how Mr. Trump might fare on Tuesday in the all-important battleground state of Florida, which is essential to his re-election.
In 2016, Mr. Trump lost the district in a rout of 16 percentage points, even as voters split their tickets and elected Mr. Curbelo, a moderate Republican, by 12 points. In 2018, Ms. Mucarsel-Powell defeated Mr. Curbelo by less than two points. That helped her nab a post on the prominent House Judiciary Committee.
Since then, the president has consolidated his support among Cuban-American Republicans and other Latinos in South Florida who gravitate toward his strongman bravado regarding Cuba and Venezuela. Mr. Gimenez left Cuba when he was 7, after the Communist revolution.
“In the 26th and even in the 27th,” Mr. Gonzales said, referring to the neighboring 27th Congressional District, “can the president overcome the potential losses among other demographics in the rest of the state?”
In other words, if Mr. Trump does better among Latinos in those districts, that might counter a possible erosion in his support among, say, older voters, enough to hold on to Florida in the presidential race — and perhaps help Mr. Gimenez scratch out an upset.
In the 27th District, Representative Donna Shalala, Democrat of Miami, is in a rematch against María Elvira Salazar, a Republican, who lost to Ms. Shalala by six percentage points in 2018. Mr. Trump endorsed Ms. Salazar on Twitter this past week, an unusual move in a district that the president lost by 20 points four years ago.
Back in the 26th, Mr. Trump has loomed large in the race from the start. Mr. Gimenez, in what he said was a coincidence, did not formally announce his candidacy until after a visit from Mr. Trump in January. The mayor met the president at the airport and, hours later, Mr. Trump gave Mr. Gimenez a Twitter endorsement.
The mayor’s embrace of the president was surprising: Mr. Gimenez said in 2016 that he voted for Hillary Clinton.
But the mayor, who golfed with Mr. Trump in 2014 when the president was a real estate developer interested in a county-owned course, moved into the White House’s good graces shortly after the 2017 inauguration. After Mr. Trump threatened to withhold federal funding from “sanctuary cities” that ignored immigration detention requests, Mr. Gimenez ordered county jails to comply, enraging immigration activists. Mr. Trump praised him on Twitter.
In a recent interview, Mr. Gimenez touted his local problem-solving record but acknowledged the partisan pressures on his candidacy.
“Other races have an effect on me — the top of the ticket,” he said. “I’m fine with endorsing him, but it doesn’t mean that I’m a 100 percent yes for anybody.”
Democrats feared that Mr. Gimenez, who has had a long public life, beginning as a paramedic in the city of Miami, might leverage his position as county mayor — the second most powerful executive in Florida, after the governor — to overwhelm Ms. Mucarsel-Powell’s re-election chances.
He was on television nearly every day at times during the pandemic, which hit Miami-Dade County hard, receiving coverage that is rarely afforded to members of Congress. With that media presence, however, came scrutiny over every virus decision, including shutting down restaurants and imposing a nightly curfew.
Ms. Mucarsel-Powell criticizes Mr. Gimenez’s pandemic leadership, saying he acted too slowly and lacked a consistent plan.
Mr. Gimenez has run as a troubleshooter with a record of getting results.
Polls showed a tight contest, with Mr. Gimenez, 66, far better-known that Ms. Mucarsel-Powell, 49. Before joining Congress two years ago, she was an associate dean at Florida International University — a position that, among other things, involved a lot of fund-raising. And so Ms. Mucarsel-Powell outraised and outspent Mr. Gimenez, reintroducing herself in sleek ads as “D.M.P.” and campaigning with the likes of Jill Biden.
In an interview, Ms. Mucarsel-Powell said she put in the work with the diverse district’s various demographics: Black Americans, including those in southern Miami-Dade County, who have suffered during the pandemic. Mexican and Central Americans whose families have labored the agricultural fields for years. White fishermen in the Florida Keys.
“You have to be able to communicate with everyone,” she said. And, taking a jab at Mr. Gimenez, she added, “I doubt he can name one person from South Dade who has lost their child to gun violence.”