COLUMBIA, S.C. - Tea party favorite Nikki Haley, a Republican candidate for governor whose campaign gained momentum with recent endorsements from Sarah Palin and Jenny Sanford, vehemently denied allegations yesterday that she had an inappropriate relationship with a political blogger several years ago.

Haley, a legislator vying to become the state's first female chief executive and replace disgraced Gov. Mark Sanford, called the claim posted yesterday on the blogger's site a smear.

She questioned the timing two weeks before the primary, saying it was an attempt to derail her campaign, once considered a long-shot.

"I have been 100 percent faithful to my husband throughout our 13 years of marriage. This claim against me is categorically and totally false," Haley, 38, a mother of two, said in a statement. "It is quite simply South Carolina politics at its worst."

The claim came from Will Folks, a conservative blogger who previously was Sanford's spokesman. Folks said the relationship took place in 2007 when he wrote speeches for Haley. He offered no proof of it and refused to go into any details.

Folks pleaded guilty to criminal domestic violence in 2005 and left the Sanford administration around that time. He is a political consultant and runs FITSNews.com, a conservative site that features commentary, thinly sourced stories of state political intrigue and photos of women in bikinis.

Folks' allegation comes nearly a year after the governor famously vanished from the state for five days, reappearing from a trip to Argentina to admit to an affair with a woman he later called his "soul mate." The scandal ended Sanford's marriage and led to calls for his resignation. He is term-limited and leaves office in January; in years past he had backed Haley's political aspirations, and his ex-wife campaigned with her earlier this month.

Haley, an accountant and three-term legislator, is in a tight race for the GOP nomination with Congressman Gresham Barrett, Lt. Gov. Andre Bauer and state Attorney General Henry McMaster.

As word of the purported relationship spread across the state and on the Internet, Haley went on at least two talk-radio shows. Callers mostly backed Haley and liked her forceful denial. They talked about South Carolina's history of unusually dirty politics and its reputation for what's been repeatedly called a "good ol' boy" network. Comments on the Internet were similar, though Folks' website had more support for him.

Folks, who said he wasn't working for any campaign, claimed he went public because political adversaries were leaking proof of it to the media to impugn his reputation and destroy her.

"The truth in this case is what it is," he wrote. "Several years ago, prior to my marriage, I had an inappropriate physical relationship with Nikki."

Folks said he owes apologies only to Haley and her family, and to his own wife for failing to reveal the relationship earlier in their marriage. He wed in 2008.

Folks left the Sanford administration about the time he received a 30-day suspended sentence for domestic violence. Folks kicked open the door at a home he shared with a lobbyist and shoved her into a piece of furniture, police said.

Folks had little political experience before joining Sanford's 2002 campaign.