Washington (CNN) -- South Carolina political operatives say Republican Sen. Lindsey Graham deftly figured out how to duck, dodge and parry the kinds of conservative challenges that have bedeviled some fellow party incumbents this primary season.
The strategy seemed twofold: Make friends in enemy camps and wield a big war chest.
To accomplish the first part, he made strategic alliances with the tea party-backed newcomers in his congressional delegation who could have posed a political threat. Those lawmakers include people such as Rep. Trey Gowdy, a former state attorney and U.S. attorney. Conservatives in the Palmetto State had hoped Gowdy would challenge the state's senior senator.
When conservative radio host Laura Ingraham asked Gowdy in July whether he would consider challenging Graham, the answer was a quick no.
Graham's alliances paid off Tuesday in South Carolina's primary. He easily topped the 50% threshold needed to avoid a runoff.
Graham's opposition was fractured heading into the primary. State Sen. Lee Bright came in a distant second, followed by five other challengers who all registered in the single digits.
Gowdy told CNN last week he had worked with Graham on several issues, ranging from debt reduction to Benghazi.
Graham and Gowdy, along with two other South Carolina congressional delegation members, Sen. Tim Scott and Rep. Mick Mulvaney, helped take the lead in sponsoring legislation this year that would allow states to opt out of the individual and employer mandate portions of Obamacare.
Both Graham and Gowdy have also been deeply critical of the Obama administration's handling of the deadly attacks on the U.S. diplomatic mission in Benghazi, Libya, in 2012 that left four Americans dead, including Ambassador Christopher Stevens. Gowdy is chairman of a newly established House committee charged with investigating those attacks.
Then there's Graham's massive war chest -- $9.4 million, a figure that far eclipses what his six opponents have been able to raise, according to the Center for Responsive Politics, a nonprofit organization which analyzes the influence of money in politics. He's used that money to target conservative strongholds and airwaves with ads, state political analysts said.
"Graham stockpiled millions of dollars and probably forced potential challengers to really wrestle with whether it was worth it to give up whatever office they might currently hold to take him on," said Nathan Gonzales, deputy editor of the Rothenberg Political Report. "That might have kept some top-tier challengers on the sidelines."
Not too shabby for a lawmaker who is reviled in some conservative Republican circles for his support of immigration reform, and prior willingness to discuss climate change and gun policy reform.
Several county party chapters censured the lawmaker for working with Democrats, and for what they see as failure to uphold conservative values, said Dave Woodard, a political science professor at Clemson University who co-wrote a book on free speech with former Sen. Jim DeMint.
"Lindsey Graham took this seriously. He knew how critical the primary was against him and he began working on it," said Woodard who is also a former GOP consultant for DeMint, Graham, Gowdy and several other South Carolina members of Congress. "He had seen some incumbent Republicans get beaten in primaries, and so he was well armed."
According to the New York Times, Graham was raised in the town of Central, South Carolina, the son of a pool hall owner, and only managed a combined score of 800 on his SATs. But he earned undergraduate and law degrees from the University of South Carolina, and has been an Air Force lawyer and a member of the U.S. House. He is known as a quick study, political analysts said.
Take for example his positioning on climate change.
In 2009, he co-sponsored a letter, along with then Sen. John Kerry, D-Massachusetts, and Sen. Joe Lieberman, then a Democrat from Connecticut, detailing support for climate change legislation. Conservatives in South Carolina were outraged.
Just a year later, Graham told the media that he questioned what he sees as an alarmist approach to climate change.
"The science about global warming has changed," he said.
Graham's shifts are a strategic appeal to conservatives in his state, political analysts said.
Hogan Gidley, a GOP consultant and a former executive director of the state party, told CNN that Graham succeeded in "tethering himself" to Scott, a favorite of the right, "touting his conservative credentials in commercials, and basically telling voters that at the end of the day he's a conservative."
CNN Political Editor Paul Steinhauser contributed to this report.