David N. Dinkins, who tenaciously climbed Harlem’s political ladder and in 1990 became New York’s first Black mayor amid hopes that he would stanch racial conflict, only to lose the office four years later as ethnic tensions continued, died Nov. 23 at his home in the city. He was 93.

A spokesman for the New York Police Department confirmed his death. The cause was not immediately available.

New York was among the last of the country’s major cities to have a Black mayor, but Mr. Dinkins drew national attention because of the tumultuous era in which he ascended to chief city executive. Rising crime, much of it racially tinged, seared the city. Fiscal constraints were strangling services, including the police.

Mr. Dinkins, a Howard University graduate, was serving as Manhattan borough president when a coalition of Black, Hispanic and labor leaders persuaded him to run for mayor in 1989.

Their aim was to oust Edward I. Koch, a Democrat seeking his fourth term as mayor who had morphed from innovative reformer to grumpy antagonist of minorities and public employee unions. His policies favored gentrification, which community activists said contributed to homelessness and hurt the working poor by raising rents.

A Washington Post profile of Mr. Dinkins called his candidacy in 1989 a preface to a “healing interlude for a city wracked by years of racial tension.” The Los Angeles Times described him as a “quiet man who dresses elegantly and oozes gentility” and questioned whether he had the grit to run the country’s biggest, most fractious city.

The Harlem Democratic machine that propelled Mr. Dinkins through his earlier posts practiced dealmaking rather than confrontation. Fostering amity among the parts of what he called “New York’s gorgeous mosaic” was his mantra.

When some Jewish residents implied that a Black mayor might not uphold law and order in inner-city areas where interracial friction was common, Mr. Dinkins used the same response in synagogues and Black churches: “I believe there are more important issues in this election than race and religion. Let’s face it. There is no Black way to fight crime, and there is no Jewish way. I offer a New York way.”

He also promised to be “the toughest mayor on crime this city has ever seen.”

Those were effective messages at the time.

Mr. Dinkins captured 50 percent of the vote in a four-way primary. But in the general election, he beat Rudolph W. Giuliani, the former U.S. attorney for the Southern District of New York, by only two points after many White voters defected. That margin, given the Democrats’ 5-to-1 registration edge, bespoke political vulnerability.

Mr. Dinkins’s policy initiatives required time to take hold, and ethnic incidents often dominated the news. During his first month, a spat between a Korean grocer and a Haitian customer escalated into a boycott by Black customers and disruptive demonstrations staged for television cameras.

Conflicts far more serious — and bloody — than the grocery fracas continued to dog the city. The mayor’s deliberate responses came across as feckless. In their 1993 rematch, Giuliani blamed him for a “pogrom” when Blacks and ultra-Orthodox Jews clashed in Brooklyn. White police officers disparaged his supposed coddling of criminals who were minorities.

When Giuliani won by two percentage points in 1993, Mr. Dinkins accepted the loss with his usual calm. “Never forget,” he told angry supporters, “that this city is about dignity.” But 20 years later, in his memoir “A Mayor’s Life,” he was candid about his feelings. “I didn’t want to say it out loud, but it’s time. Now I say, racism, plain and simple.”

Little in New York’s political culture is simple.

“Dinkins served in very difficult circumstances, but he did not respond effectively,” Mitchell L. Moss, a professor of urban policy and planning at New York University, said in an interview for this obituary. “I don’t think he fully understood how much people expected of him.”

The most dramatic example of that was the city’s response to rioting in the Crown Heights neighborhood of Brooklyn in 1991.

Friction between Blacks and their Hasidic Jewish neighbors was constant. One evening, a car in a Hasidic motorcade lurched onto a sidewalk, killing a 7-year-old Black child, Gavin Cato, and injuring another. Anger escalated, crowds formed and hours later Black youths stabbed to death a Hasidic student, 29-year-old Yankel Rosenbaum. They reportedly chanted “Kill the Jew.”

Disturbances dragged on for three more nights, causing scores of injuries and millions of dollars in property damage.

Mr. Dinkins’s personal efforts to bring calm elicited rocks and bottles. The initial police response was poorly coordinated.

When Police Commissioner Lee P. Brown — a Dinkins appointee who had led police departments in Atlanta and Houston — visited the scene, his car was stolen. Only after Deputy Commissioner Raymond W. Kelly took charge was order fully restored. Kelly replaced Brown in 1992.

The blanket coverage given Crown Heights obscured the administration’s gains in law enforcement. Although he inherited Koch’s deficit and the national recession was crimping revenue, Mr. Dinkins managed to balance the budget each of his four years, while beginning a police buildup that ultimately added 6,000 to the force.

Brown (who later became a three-term mayor of Houston) created a community policing program that increased the percentage of officers on street patrol. In the second half of Mr. Dinkins’s term, the overall crime rate fell 14 percent and the homicide rate 12 percent. It was the first time that crime had declined in a dozen years.

The police department received budget increases; other agencies suffered cuts. But Mr. Dinkins’s relations with rank-and-file officers soured.

After a police officer in July 1992 fatally shot Jose Garcia — a 23-year-old immigrant from the Dominican Republic, a father of two and a convicted drug dealer — disturbances erupted in the victim’s largely Dominican neighborhood of Washington Heights in northern Manhattan. (A Manhattan grand jury did not indict the officer, who said he fired after Garcia pulled a gun on him during a struggle.)

The mayor enraged police officers and many political leaders when, in an effort to calm community rage, he paid a condolence call on the Garcia family and had the city pay for Garcia’s funeral in the Dominican Republic.

Mr. Dinkins spent months trying to win back police allegiance. Alluding to his campaign slogan of a “gorgeous mosaic,” he told one gathering of officers, “The color blue is definitely part of that mosaic.”

Police support withered even more that year when the mayor threw his support for an all-civilian, independent agency to investigate allegations of police abuse. The police union had been bitterly opposed to the creation of the Civilian Complaint Review Board since the idea was first floated seriously in the 1960s.

In September 1992, a union meeting of off-duty patrolmen led to an unruly march on City Hall. Demonstrators shouted racial epithets. Three Black city council members were insulted while being prevented from going to their offices. Mr. Dinkins later denounced the protest as “bordering on hooliganism.”

By December, the city council approved the review board. Giuliani, who unrelentingly painted Mr. Dinkins as a foe of the police, soon brought Mr. Dinkins’s political career to an end.

David Norman Dinkins was born July 10, 1927, in Trenton, N.J., where his father, William, ran a one-chair barbershop. He was 6 when his parents separated, and he mostly grew up with his father and stepmother, an English teacher.

After high school graduation in 1945 — where he was elected president of his homeroom class — Mr. Dinkins tried to enlist in the Marine Corps in the closing months of World War II. He was initially rejected by the Marines on the grounds that its “Negro quota” was full.

He entered the Army and, through perseverance, transferred to the Marine Corps and spent 13 months in uniform, mostly at Camp Lejeune in North Carolina. After his discharge, he used the GI Bill to study mathematics at Howard University in Washington and graduated in 1950.

In 1953, he married a fellow Howard graduate, Joyce Burrows, and settled in the Harlem neighborhood in New York, where her father was a businessman with political connections. Joyce Dinkins died in October. Survivors include two children; a sister; and two grandchildren.

After graduating from Brooklyn Law School in 1956, Mr. Dinkins became involved in clubhouse politics. With his father-in-law as an intermediary, Mr. Dinkins became a protege of Raymond “The Fox” Jones, who ran the Democratic apparatus in Harlem.

“Dinkins understood the rules and played by the rules,” Jones wrote later. “I was his patron.”

That patronage led to one term as a state assemblyman in the mid-1960s — he chose not to run after the district was redrawn — and later the chairmanship of the city Board of Elections. Mr. Dinkins was a political player in his own right by the time Abraham D. Beame (D) won the mayoralty in 1973.

Beame rewarded Mr. Dinkins’s campaign support with a nomination to the key post of deputy mayor. But failure to pay taxes for three years — he had filed for extensions — torpedoed the appointment.

Beame gave him a consolation prize: the office of city clerk, a position that provided Mr. Dinkins ample time to rebuild political strength. The job he really wanted was Manhattan borough president, which had administrative and legislative clout under the city charter then in force. In 1985, on his third try, he won.

After Mr. Dinkins left City Hall at the end of 1993, a friend who co-owned a Black-oriented radio station, WLIB, arranged for a semiweekly talk show. Supporters in the business world provided memberships on corporate boards. He taught a class at the Columbia University School of International and Public Affairs. A tennis lover all his adult life, Mr. Dinkins was frequently seen at the public courts in Central Park, where fellow players invariably greeted him warmly.

Although his rocky tenure and ultimate defeat left lingering bitterness, Mr. Dinkins took solace in repeating, 20 years later, what he said in his concession speech: “My friends, we have made history. Nothing can ever take that away.”