You will likely be interested in this previous question:
I normally try to write a quick summary here but, as you gather, Goldwater is a hard man to summarize. While he worked for civil rights at various points in career, he was also a strong libertarian and didn’t care for the federal government regulating this things.
Honestly, in reviewing all this stuff, I think that Goldwater genuinely does seem opposed to racism and segregation. He just sees this as a personal or state issue, so ends up de facto empowering the racists. He even opposed Eisenhower's use of troops to enforce the Brown decision, saying "Leave them alone. They will eventually have integrated schools." (this is on page 220 of his biography by Lee Edwards). When someone asked him in 1963 how someone might resist the Brown decision, he said, "The idea is not to resist it. There is nothing in the Constitution that says a person can violate the law. Neither is there anything that says a state can violate the law." He said he would have voted for the 1964 Civil Rights Act if Section II (on public accommodations, including housing) and Section VII (on equal employment opportunity) were removed.
Because of his objection to those sections of the Civil Rights Act, he got the support of many of the racists and segregationists in the 1964 election—support that he welcomed. He seemed to care about Black civil rights... but he also cared about a lot of other things a lot more.
I think the whole thing is worth reading, and the follow up posts, as Goldwater is really a rare figure in Washington, a True Believer. He was also a political opportunist, though as mentioned above less of one than his aids often wanted him to be.
Unfortunately missing from that answer is a lengthy analysis of what exactly Goldwater did in the 1964 campaign. What I wrote was largely meant as a companion piece in response to a now deleted comment detailing the campaign. This comment discussed a lot of “dog whistle” and symbolic politics Goldwater and his campaign engaged in, trying to reassure Southern voters had little intention to interfere with segregation after (mostly Northern) Democrats began pushing a national legislative program of civil rights of which the Civil Rights Act of 1964 was only the beginning.
To offer some context for the 1964 campaign, let me quote this New Yorker article from the time, The Campaign: Goldwater from the October 3rd, 1964 edition:
Still, the Goldwater movement, whether or not it can command a majority, remains an enormous one in the South and appears to be a racist movement and almost nothing else. On his tour, Goldwater seemed fully aware of this and not visibly distressed by it. He did not, to be sure, make any direct racist appeals. He covered the South and never, in any public gathering, mentioned “race” or “Negroes” or “whites” or “segregation” or “civil rights.” But the fact that the words did not cross his lips does not mean that he ignored the realities they describe. He talked about those realities all the time, in an underground, or Aesopian, language—a kind of code that few in his audiences had any trouble deciphering. In the code, “bullies and marauders” means “Negroes.” “Criminal defendants” means negroes. States rights means “opposition to civil rights.” “Women” means “white women.” This much of the code is as easily understood by his Northern audiences as by his Southern ones, but there are also some words that have a more limited and specific meaning for the Southern crowds. Thus, in the Old Confederacy “Lyndon Baines Johnson” and “my opponent” means “integrationist.” “Hubert Horatio” (it somehow amuses Goldwater to drop the “Humphrey”) means “super-integrationist.” “Federal judiciary” means “integrationist judges.” It would be going too far to say that Goldwater touched Southern sensibilities on race when he brought up Bobby Baker, the TFX controversy, fiscal policy, or “Yo-yo” McNamara, and he certainly was not arousing them when he talked of the T.V.A. in Knoxville and Medicare in Orlando. One always had the feeling, though, that the Goldwater Republicans in the South could find a racial or regional angle in almost anything. When the name of Bobby Baker—a Pickens, South Carolina, man who once enjoyed a friendly relationship with Senator Thurmond—was hooted at Goldwater meetings (as it was everywhere except in Greenville, where delicacy prevailed and he was not mentioned), it was not because the speaker was deploring Baker’s activities in business and politics. It was because of his embarrassing connections with the integrationist in the White House. And Goldwater generally played it that way. He would rattle off some figures on murders, rapes, and muggings, explain that “nothing is more clear from history than that the moral decay of a people begins at the top,” and follow this with a quick mention of Bobby Baker, as if Bobby Baker were some kind of hoodlum lieutenant and riot organizer, rather than a conspicuously successful entrepreneur. Among Goldwater Southerners, even thermonuclear warfare gets identified with regional pride, sentiment, and rancor. An Atlanta matron, bedecked with Goldwater-Miller buttons, was asked if she had ever been disturbed by things the candidate had said about war and weaponry. “Certainly not,” she replied. “We’re not cowards down here.”
The only appeal Goldwater really had in the traditionally Democratic (since “Redemption”) South was various shades of then racial, “pro-states rights” message, and he trotted it out everywhere. The article, it should be said, also notes that, even with these dog whistles, Goldwater was only sure in few states, as parts of the formerly Democratic “Solid South” were solidly Democratic, and other parts seemed closely split between Goldwater and Johnson:
Though one saw little evidence of it at the Goldwater pageants and picnics, the South has more on its mind than race. Opinion polls show the region as a whole to be just about evenly split between the candidates. Goldwater cannot lose Alabama, where the President will not be on the ballot, and he should have no trouble winning Mississippi, where the Democratic organization has put up a slate of Johnson electors and urged everyone to vote against them. It would surprise most experts if Johnson won Louisiana, where Goldwater has more billboard space than Ford, Chrysler, and General Motors put together; it would also surprise most experts if the President lost Georgia, Arkansas, the Carolinas, and Texas. But in most places the division is expected to be close. There are, plainly, large numbers of Southerners—white Southerners—who will cast their votes on issues other than race. In August, Representative Ross Bass, of Tennessee, one of the two Southern Democrats to vote for the Civil Rights Bill, easily won a nomination for senator against a segregationist. In late September, Representative Harry Wingate, Jr., of Georgia, the one Democrat whom Goldwater endorsed on the Southern tour, lost his seat, in a district said to be full of racists of the most benighted sort, to a man supporting the national administration.