WASHINGTON — The Wisconsin primary — Hillary Clinton’s sixth loss in a row — was a warning shot across her bow: She’s at risk of becoming the national version of Martha Coakley.

Clinton is veering dangerously close to the fate Coakley famously suffered in the 2010 Massachusetts U.S. Senate race, when she took winning for granted and got the surprise of her life from populist Republican Scott Brown. Instead of trying to court the enthusiasm that has fueled Bernie Sanders’ current surge at the polls and in fundraising, Clinton is trying to kill it. And as the crucial April 19 New York contest looms, she can’t ?afford more mistakes.

“She has allowed a 74-year-old socialist from Vermont to beat her in lot of contests she should be winning. That’s a problem,” said Democratic strategist Scott Ferson. “If she loses New York, she’d be like Martha Coakley … on her way to being Jimmy Carter ?in 1980.” Readers will recall that the sitting president fought off a primary challenge by a late-surging Bay State U.S. Sen. Edward M. Kennedy, but emerged so battered that Ronald Reagan beat him soundly in the end. Clinton, too, will emerge victorious in July. But viciously attacking Sanders now could cost her voters she’ll need in November.

“His ideas just won’t work ?because the numbers don’t add ?up,” Clinton said in Philadelphia yesterday.

Sorry, but Clinton can’t woo Sanders’ fervent supporters by telling them it’s time to give up their dream of what America ?should be, and eat their peas like good Democrats.

It doesn’t help that Clinton ?already was lagging in likeability — and that Coakley-like, she has spent most of this race aloof from voters, acting like the nomination is already hers.

Other attacks, like Clinton’s claim that Sanders stood with gun makers and against the Sandy Hook massacre families, prompted Sanders’ campaign manager Jeff Weaver to suggest that Clinton could “destroy the party” in pursuit of the nomination when she should be forging party unity. Clinton laughed loudly when ?she was asked about that on ?CNN yesterday.

“I mean, it’s just ludicrous on the face of it,” she said, getting in another jab between chuckles. “Sen. Sanders by his own admission has never even been a Democrat.”

Ironically, Clinton’s campaign is driven in part by her deep ?desire not to be a two-time loser — as Coakley was after the 2014 governor’s race. Clinton lost the 2008 presidential primary and she doesn’t want a repeat.

“This is the byproduct of the scars that she bears from being the front-runner and having someone run her over and become president of the United States,” Democratic strategist Dan Cence said of Clinton’s aggressive stance.

“It’s a mistake,” said former Massachusetts Democratic Party chairman Phil Johnston, a Sanders backer. “We can’t win in November with just Democrats, we need independents.”

If Clinton’s strategy backfires, at least she’ll have Coakley to call. She’ll understand.