Mr. Adams, who ran a campaign focused on appealing to blue-collar Black and Latino voters, said America does not want “fancy candidates.”He bluntly challenged left-wing leaders in his party over matters of policing and public safety. He campaigned heavily in Brooklyn, Queens and the Bronx, often ignoring Manhattan neighborhoods besides Harlem and Washington Heights. And he branded himself a blue-collar candidate with a keen personal understanding of the challenges and concerns facing working-class New Yorkers of color.With his substantial early lead in the Democratic mayoral primary when votes were counted Tuesday night, Eric Adams, the Brooklyn borough president, demonstrated the enduring power of a candidate who can connect to working- and middle-class Black and Latino voters, while also appealing to some white voters with moderate views.Mr. Adams is not yet assured of victory. But if he prevails, it would be a triumph for a campaign that focused more heavily on those constituencies than any other winning New York City mayoral candidate in recent history.As the national Democratic Party navigates debates over identity and ideology, the mayoral primary in the largest city in the United States is highlighting critical questions about which voters make up the party’s base in the Biden era, and who best speaks for them.Barely a year has passed since President Biden clinched the Democratic nomination, defeating several more progressive rivals on the strength of support from Black voters and older moderate voters across the board, and running as a blue-collar candidate himself. But Democrats are now straining to hold together a coalition that includes college-educated liberals and centrists, young left-wing activists and working-class voters of color.“America is saying, we want to have justice and safety and end inequalities,” Mr. Adams declared at a news conference on Thursday, offering his take on the party’s direction. “And we don’t want fancy candidates.”Mr. Adams’s allies and advisers say that from the start, he based his campaign strategy on connecting with working- and middle-class voters of color.“Over the last few cycles, the winners of the mayor’s race have started with a whiter, wealthier base generally, and then expanded out,” said Evan Thies, an Adams spokesman and adviser. Mr. Adams’s campaign, he said, started “with low-income, middle-income, Black, Latino, immigrant communities, and then reached into middle-income communities.”Mr. Adams would be New York’s second Black mayor, after David N. Dinkins. Mr. Dinkins, who described the city as a “gorgeous mosaic,” was more focused than Mr. Adams on trying to win over liberal white voters.Mr. Adams was the first choice of about 32 percent of New York Democrats who voted in person on Tuesday or during the early voting period. Maya Wiley, a former counsel to Mayor Bill de Blasio and a progressive favorite, pulled in about 22 percent of that vote. Kathryn Garcia, a former sanitation commissioner who touted her managerial experience, got 19.5 percent.Under the city’s new ranked-choice system, in which voters could rank up to five candidates, the Democratic nominee will now be determined through a process of elimination. Ms. Garcia or Ms. Wiley could ultimately surpass Mr. Adams, although that appears to be an uphill battle, and a final winner may not be determined for weeks.Kathryn Garcia, a former city sanitation commissioner, is in third place after the initial, Primary Day counting of votes.Desiree Rios for The New York TimesIf Mr. Adams does win, it will be partly because he had major institutional advantages.He was well financed and spent heavily on advertising. He received the support of several of the city’s most influential labor unions, which represent many Black and Latino New Yorkers. His name was also well known after years in city politics, including as a state senator.And although some of the most prominent members of New York’s congressional delegation supported Ms. Wiley as their first choice, Mr. Adams landed other important endorsements, including those of the Queens and Bronx borough presidents and Representative Adriano Espaillat, the first Dominican-American member of Congress, and a powerful figure in Washington Heights.Just as importantly, in his supporters’ eyes, Mr. Adams was perceived as having credibility on what emerged as the most consequential, and divisive, issue in the race: public safety.Mr. Adams, who experienced economic hardship as a child and has said he was once beaten by police officers, grew up to join the Police Department, rising to captain. Critics within the department saw him as something of a rabble-rouser, while many progressive voters now think his answers to complex problems too often involve an emphasis on law enforcement.But to some voters, he long ago cemented a reputation as someone who challenged misconduct from within the system, giving him authority to talk about bringing down crime.“He was in the police force, he knows what they represent,” said Gloria Dees, 63, a Brooklyn resident who voted for Mr. Adams and described being deeply concerned about both rising crime and police violence against people of color. “You have to understand something in order to make it work better.”Polls this spring showed public safety increasingly becoming the most important issue to Democratic voters amid random subway attacks, a spate of bias crimes and a spike in shootings. On the Sunday before the primary, Mr. Adams’s campaign staff said that a volunteer had been stabbed in the Bronx.“Being an ex-cop, being able to have safety and justice at the same time, was a message that resonated with folks in the Bronx,” said Assemblywoman Karines Reyes, a Democrat who represents parts of the borough and who did not endorse anyone in the race. Mr. Adams won the Bronx overwhelmingly in the first vote tally. “They’re looking for somebody to address the crime.”Voters cast ballots in the Bronx’s Mott Haven neighborhood on Primary Day. Public safety emerged as the dominant issue in the race. Desiree Rios for The New York TimesThe rate of violent crime in the city is far below where it was decades ago, but shootings have been up in some neighborhoods, and among older voters especially, there is a visceral fear of returning to the “bad old days.”Donovan Richards, the Queens borough president and a supporter of Mr. Adams, cited the recent fatal shooting of a 10-year-old boy in the Rockaways as something that hit home for many people in the area.“We’re nowhere near where we were in the ’80s or ’70s,” he said. But, he added, “when you see a shooting in front of you, no one cares about statistics.”Interviews on Thursday with voters on either side of Brooklyn’s Eastern Parkway illustrated vividly Mr. Adams’s appeal and limitations. In parts of Crown Heights, the parkway was a physical dividing line, early results show, between voters who went for Ms. Wiley and those who preferred Mr. Adams.Among older, working-class voters of color who live south of the parkway, Mr. Adams held a commanding lead. “He’ll support the poor people and the Black and brown people,” said one, Janice Brathwaite, 66, who is disabled and said she had voted for Mr. Adams.“He’ll support the poor people and the Black and brown people,” Janice Brathwaite, who lives in Brooklyn’s Crown Heights neighborhood, said of Mr. Adams. Andrew Seng for The New York TimesMs. Brathwaite ruled out Ms. Wiley after hearing her plans for overhauling the Police Department, including a reallocation of $1 billion from the police budget to social service programs and anti-violence measures.“She is someone who is against the policeman who is protecting me, making sure nobody is shooting me,” Ms. Brathwaite said.Ms. Wiley has said there are times when armed officers are needed, but she has also argued that in some instances, mental health experts can halt crime more effectively.That approach appealed to Allison Behringer, 31, an audio journalist and podcast producer who lives north of the parkway, where Mr. Adams’s challenges were on display among some of the young professionals who live in the area.“She was the best progressive candidate,” Ms. Behringer said of Ms. Wiley, whom she ranked as her first choice. “She talked about reimagining what public safety is, that really resonated with me.”Ms. Behringer alluded to concerns about ethical issues that have been raised about Mr. Adams. He has faced scrutiny over his taxes, real estate holdings, fund-raising practices and residency.A fresh round of voting results to be released on Tuesday will provide further clarity about the race. They may show whether those issues hurt Mr. Adams among some highly engaged voters in Manhattan and elsewhere. The new results could also indicate whether Ms. Wiley or Ms. Garcia had sufficiently broad appeal to cut into his lead.As in Brooklyn, there was a clear geographic divide among voters in Manhattan: East 96th Street, with those who ranked Ms. Garcia first mostly to the south, and those who favored Mr. Adams or Ms. Wiley further uptown.Ms. Garcia, a relatively moderate technocrat who was endorsed by The New York Times’s editorial board, among others, won Manhattan handily. Like Ms. Wiley, she hopes to beat Mr. Adams by being many voters’ second choice, and with the benefit of absentee votes that have not been counted.Maya Wiley, center, ranked second in first-choice votes in the initial count of in-person ballots.Hilary Swift for The New York TimesIn Harlem one afternoon this month, Carmen Flores had just cast her early vote for Mr. Adams when she came across one of his rallies. She said she found his trajectory inspiring.“He’s coming from the bottom up,” she said, adding, “He’s been in every facet of life.”Whatever the final vote tally, Democratic strategists caution against drawing sweeping political conclusions from a post-pandemic, municipal election held in June. If Mr. Adams becomes mayor, as the Democratic nominee almost certainly will, progressive leaders can still point to signs of strength in other city races and elsewhere in the state.Asked about the mayor’s race, Waleed Shahid, a spokesman for the left-wing organization Justice Democrats, said, “fear-mongering works when crime is rising,” while noting that several left-wing candidates in the city were leading their races. He also argued that some people who supported Mr. Adams could have done so for reasons that were not ideological.“There might be some voters who voted for Eric Adams based on his policy platform,” Mr. Shahid said. “But there are probably many more voters who voted for Eric Adams based on how they felt about him. It’s often whether they identify with a candidate.”Nate Schweber contributed reporting. More