I have never understood why so many blacks support the Democrats. When you understand that the Democrats were the party of the Klu Klux Clan and George Wallace, it makes no sense at all.
In part it started with Richard Nixon in 1960.
Nixon and Martin Luther King were actually friendly, if not friends, and Nixon had a good record on working towards equal rights legislation.
King, as can be imagined, was a staunch Republican supporter.
Then, in the middle of the 1960 presidential campaign (October 19, 1960), King was arrested and sentenced to 4 months in prison on an old, and quite specious, charge. Coretta King and others in his circle were afraid that it was a pretext to have King killed in prison, so they reached out to Nixon.... who did nothing, apparently because he didn't want to alienate Southern whites. Basically, he cowarded out and hung a friend out to dry.
Kennedy aides got JFK to call Mrs. King and express support, and then Bobby Kennedy called the judge and read him the riot act. King was released on October 27.
It's debated how much this call affected African American perception in the run up to the presidential election, but Kennedy did get more than an expected share of that voting block.
With Kennedy in power, he started pushing equal rights legislation, including the voting rights act. After Johnson took office, he doubled down and helped ramrod the voting rights act and other legislation through Congress, which led to a number of hardcore segregationist Congressmen switching party affiliation from Democrat to Republic.
When the Voting Rights Act was signed into law, King and Rosa Parks were behind Johnson.
In 1960, Kennedy won 68% of the non-white vote, which was really in line with how the non-white vote had trended since the Roosevelt days of the New Deal.
But in 1964, after he came out strongly for civil rights legislation (and created a perception that Goldwater was an oldtime Southern racist), Johnson took 94% of the nonwhite vote.
In 1968 and 1972, despite Nixon's record supporting equal rights legislation, the Democratic candidates took over 85%+ of the vote, a trend that has largely continued to this day.