Bill and Hillary Clinton are angry with efforts by mayoral hopeful Anthony Weiner and his campaign to compare his Internet sexcapades — and his wife Huma Abedin’s incredible forgiveness — to the Clintons’ notorious White House saga, The Post has learned.

“The Clintons are upset with the comparisons that the Weiners seem to be encouraging — that Huma is ‘standing by her man’ the way Hillary did with Bill, which is not what she in fact did,’’ said a top state Democrat.

Weiner and his campaign aides have explicitly referred to the Clintons as they privately seek to convince skeptical Democrats that voters can back Weiner despite his online sexual antics — just as they supported then-President Bill Clinton in the face of repeated allegations of marital betrayals.

“The Clintons are pissed off that Weiner’s campaign is saying that Huma is just like Hillary,’’ said the source. “How dare they compare Huma with Hillary? Hillary was the first lady. Hillary was a senator. She was secretary of state.”

A longtime Hillary aide and Clinton friend, Abedin’s surprisingly unequivocal support of her husband after his bombshell admission Tuesday that he engaged in salacious online sexting well after he resigned in disgrace from Congress in 2011 left the Clintons stunned, continued the source.

EXCLUSIVE PHOTOS: ANTHONY WEINER SEXT GAL’S BIKINI PHOTO SHOOT

“Hillary didn’t know Huma would do this whole stand-by-your-man routine, and that’s one of the reasons the Clintons are distancing themselves from all this nonsense,’’ the source said.

In the view of many Democrats, the Weiners have also alluded more subtly to the Clintons.

For instance, Abedin, with her husband at her side, declared last week, “Our marriage, like many others, has had its ups and its downs.’’

“Who didn’t think Huma was referring to the Clintons when she said that?’’ asked another prominent Democrat.

Worried about the potential impact on Hillary’s likely run for president in 2016, the political power couple has begun aggressively distancing itself from the crippled mayoral contender, according to sources.

Meanwhile, at least one prominent Hillary Rodham Clinton political operative was described as close to “going public’’ with a sharp criticism of Weiner — in order to send the message that the Clintons, fearing longtime damage to Hillary, want him out of the mayor’s race. (That would be someone other than former Clinton White House Press Secretary Dee Dee Myers, who said yesterday that she was sure the Clintons wanted Weiner out of the race.)

With all the explosive ammunition Republicans have to fire at Weiner and a handful of other disgraced Democrats, GOP activists expected Senate co-leader Dean Skelos and Assembly Minority Leader Brian Kolb to unload at least a few critical comments.

Instead, there’s been total silence from the state’s two top elected Republicans — in yet another example of the collapse of the state’s two-party system.

Skelos “couldn’t care less about what’s going on with the Democrats. He’s just focused on . . . sending out meaningless tweets,’’ said a Republican strategist.