McCain has faced a barrage of criticism, with some comparing the situation to the controversy faced by Democratover the views of his former pastor, the Rev. Jeremiah Wright.
"John Hagee has been a thorn in John McCain's side for months now," said CBS News correspondent Chip Reid.
McCain rejected the months-old endorsement of Texas preacher Hagee after an audio recording surfaced in which the preacher said God sent Adolf Hitler to help Jews reach the promised land. McCain called the comment "crazy and unacceptable."
He later also repudiated the support of Rod Parsley, an Ohio preacher who has sharply criticized Islam and called the religion inherently violent.
McCain issued a statement Thursday afternoon announcing his decision about Hagee.
"Obviously, I find these remarks and others deeply offensive and indefensible, and I repudiate them. I did not know of them before Reverend Hagee's endorsement, and I feel I must reject his endorsement as well," he said.
Later, in Stockton, he told reporters: "I just think that the statement is crazy and unacceptable."
CBS News has learned that one of the reasons that McCain distanced himself from Hagee was that the San Antonio minister was preparing to withdraw his endorsement.
Then in an interview with The Associated Press, McCain said he rejected Parsley's support, too.
"I believe there is no place for that kind of dialogue in America, and I believe that even though he endorsed me, and I didn't endorse him, the fact is that I repudiate such talk, and I reject his endorsement," McCain told the AP.
Hagee had sparked controversy since the San Antonio pastor endorsed McCain on Feb. 27 shortly before the Texas presidential primary. Parsley's views were aired Thursday in an ABC News report.
McCain actively courted Hagee, who leads a megachurch with a congregation in the tens of thousands and has an even wider television audience. Former GOP presidential rivals also sought Hagee's backing.
Hagee has referred to the Roman Catholic Church as "the great whore" and called it a "false cult system." He also has linked Hitler to the Catholic church, suggesting it helped shape his anti-Semitism. And Hagee said Hurricane Katrina was God's retribution for homosexual sin.
McCain has faced a barrage of criticism over Hagee, with some comparing the situation to the controversy Democrat Barack Obama faced over the views of his longtime and now former pastor, the Rev. Jeremiah Wright.
McCain tried Thursday to draw a distinction between the Obama-Wright connection and his own relationships with Parsley and Hagee, saying Hagee was not his pastor.
"My church I attend is North Phoenix Baptist Church; my pastor and spiritual guide is Pastor Dan Yeary," McCain said. "I've never been to Pastor Hagee's church or Pastor Parsley's church. I didn't attend their church for 20 years. I'm not a member of their church."
Obama, who was campaigning in Florida, said that in national politics it's easy to find people who have said or done offensive things.
"John McCain has to deal with Hagee, who said something that is mind-boggling. I don't attribute those statements to John McCain. Nobody thinks McCain believes that stuff," Obama said. "And for McCain to then suggest that every single statement that was made by somebody is somehow attributable to me is just wrong. It is just not accurate."
Until now, McCain had tried to distance himself from Hagee's views but had not rejected the endorsement.
"I'm glad to have his endorsement," he said on ABC's "This Week" in April. "I condemn remarks that are, in any way, viewed as anti-anything."
The Arizona senator has said he sought Hagee's support because the pastor, like himself, is a strong supporter of Israel.
The formation of Israel was at the heart of the remarks that prompted McCain to reject Hagee's support. The comments came in a sermon Hagee gave in the late 1990s, an audio recording of which was posted last week on the liberal blog Talk to Action and reported by The Huffington Post, another liberal blog.
In the sermon, Hagee said, "Then God sent a hunter. A hunter is someone with a gun, and he forces you. Hitler was a hunter. ... How did it happen? Because God allowed it to happen. Why did it happen? Because God said, 'My top priority for the Jewish people is to get them to come back to the land of Israel."'
Hagee tried to repair the damage by apologizing to Catholics in a letter released just last week. Saying he had emphasized the darkest chapters in the history of Catholic and Protestant relationships with Jews, Hagee wrote, "I want to express my deep regret for any comments that Catholics have found hurtful."
On Thursday, Hagee issued a new statement saying he was weary of the controversy and was withdrawing his endorsement.
Hagee said critics are "grossly misrepresenting my position on issues most near and dear to my heart."
"I am tired of these baseless attacks and fear that they have become a distraction in what should be a national debate about important issues," Hagee said. "I have therefore decided to withdraw my endorsement of Senator McCain for president effective today, and to remove myself from any active role in the 2008 campaign."
The other pastor, Parsley, has described Islam as an "anti-Christ religion" and the Muslim prophet Muhammad as "the mouthpiece of a conspiracy of spiritual evil," according to ABC News.