Herman D. Farrell Jr., a perennial New York State Democratic assemblyman from Manhattan and one of the last survivors of Harlem’s political Old Guard, died on Saturday in a Manhattan hospital. He was 86.

The cause was heart failure, his son, Herman D. Farrell III, said.

Mr. Farrell, who was known as Denny, was first elected in 1974 and retired when his term ended in 2017. He was also the chairman of the New York State Democratic Committee from 2001 to 2006, the first black person to hold that post, and headed the fractious Manhattan party confederacy from 1981 to 2009, longer than any of his predecessors.

From the beginning of his public career, Mr. Farrell distinguished himself from most politicians. Towering over his colleagues at 6 feet 4 inches, he dressed impeccably, comported himself like a gentleman, was both candid and trustworthy, was endowed with a wry wit and, untainted, he survived the corruption and sexual scandals that doomed so many city and state officials.

Mr. Farrell had no illusions about the waning power of New York’s political bosses.

Nor did he wonder why contemporary political leaders were no longer denigrated as latter day versions of William M. Tweed or Frank Hague; they had become, in his view, more like referees.