Despite a deluge of debate-night gaffes and sagging poll numbers, Joe Biden is poised to take on Bernie Sanders virtually head to head on Super Tuesday — thanks in large part to a Democratic Party establishment that fears having the socialist Sanders atop its 2020 ticket, insiders said Monday.

Pete Buttigieg and Sen. Amy Klobuchar suspended their campaigns on Sunday and Monday, respectively, and said they would endorse fellow moderate Biden, in a last-ditch effort to stop the Vermont senator, who appeared to be steamrolling toward big wins in delegate-rich states like California and Texas.

“That’s a big show of force that the left-of-center wing of the Democratic Party is consolidating around Joe because they understand what’s at stake,” Adrienne Elrod, a Democratic strategist and veteran of Hillary Clinton’s White House bids, told NBC News.

“They don’t want this to be handed to Bernie Sanders on Super Tuesday.”

Other party insiders agreed that the pair stepped aside in support of their moderate cause.

“The candidates are looking at the numbers. If you don’t have a path to the nomination, you’re only hurting your cause,” Jay Jacobs, the New York state Democratic chairman and a Democratic National Committee superdelegate, told The Post.

“Moderates who split the vote help the far-left candidate, Bernie Sanders,” added Jacobs.

With Buttigieg, the former mayor of South Bend, Ind., and Klobuchar, of Minnesota, treading water in the race, bowing out and throwing their weight behind Biden represented a win for their backers, who may not be ready to embrace a self-avowed Democratic socialist like Sanders, who recently praised the late Cuban dictator Fidel Castro.

“Where I come from, Bernie’s message doesn’t resonate with a majority of voters,” said Jacobs, a longtime leader of the Nassau County Democratic Party. “You have to take that into account.”

While Buttigieg and Klobuchar may have done that calculus on their own, one DNC insider said they were also facing external pressure to back Biden — fresh off his big win in South Carolina Saturday — from Democratic donors queasy over Sanders’ electability and the effect he could have at the top of the ticket on House and Senate races.

An internal poll conducted by Mike Bloomberg’s campaign last month found that Sanders would “jeopardize” the re-election of 42 House Democrats in battleground districts and therefore the party’s majority rule of the chamber if he becomes the party’s nominee for president.

Still, said the source, “Everyone’s worried that it’s too late. Joe has nothing on the ground on Super Tuesday.”

The source also fretted that the tactic could backfire, should Sanders try to energize his base with fresh denunciations of deep-pocketed donors influencing politics.

President Trump offered an alternate explanation for Buttigieg and Klobuchar’s backing of Biden, speculating to reporters that they were angling for posts in a potential Biden White House.

“That’s called a quid pro quo, right?” asked Trump, in a playful apparent reference to Democrats’ allegations that he tried to set up a quid pro quo with Ukrainian President Volodymyr Zelensky to probe Biden and his son as an American aid package hung in the balance.

Klobuchar, meanwhile, may have been influenced by fears of an embarrassing loss to Sanders in her home state’s primary Tuesday, a DNC source said.

According to RealClearPolitics’ average of February polls, Klobuchar held a six-point edge over Sanders heading into Super Tuesday, when Minnesota is one of 14 states holding its primary.

Biden and Sanders will compete with Massachusetts Sen. Elizabeth Warren, former New York Mayor Bloomberg and Hawaii Rep. Tulsi Gabbard for 1,357 delegates on Tuesday.

The contests are not winner-take-all, but rather proportional, meaning that a blowout victory does more to boost a candidate’s cause than a nail-biter win.

However, candidates will only be awarded delegates for states and districts in which they snag at least 15 percent of the vote, meaning that on-the-bubble hopefuls Warren and Bloomberg can either resuscitate their campaigns — and spoil Biden and Sanders in the process — or go home empty-handed.

The biggest prize is California, with its 415 delegates.

As of a RealClearPolitics average spanning February and the first two days of March, Sanders led in the Golden State with 34.7 percent, followed by Biden with 18 percent — with Warren and Bloomberg straddling the cutoff at 15.3 percent and 13 percent, respectively.

Additional reporting by Ebony Bowden and Mark Moore