Hedge funds are dancing with the devil.

They are facing a crisis of confidence and potential lawsuits amid unprecedented fund closures, job losses and — most critically — low investment returns.

It’s finally time to bail, one money man in Short Hills, NJ, warned last week of these leveraged alternative investments for superwealthy and not-so-wealthy middle-class investors.

“Get out,” echoed financial adviser Stephen Ng, as more unwelcome news hit hedgies. “I have been talking about this — and now I think more and more investors are beginning to realize it.”

With just over $3 trillion in assets under management globally, hedge fund magnates are anxiously awaiting a recovery from last year’s feeble industry returns of 5.5 percent, compared with 10 percent for the S&P 500-stock index.

Investors already withdrew $111.6 billion from hedge funds last year, according to eVestment, as some 1,100 funds — the largest total since the 2008 financial crisis — closed, and thousands of pros were axed.

About 9,700 hedge funds remain. “These funds have very good marketing,” said Ng. “But you can also lose 50 or 100 percent of your money.”

While some individual funds certainly had market-beating returns and this year had early glimmers of hope, the year-to-date performance of the HFRI Fund Weighted Composite Index stands at a paltry 3.5 percent.

That’s easily eclipsed by the more than 9 percent return for the S&P 500, meaning the hedge fund industry overall is way behind.

Sensing that funds were trailing the market indexes, investors in April pulled $930 million, according to eVestment data.

That’s as more funds closed last week, according to Hedge Fund Research.

“What has clearly gone down are the returns, and we’re seeing some superstars getting deflowered, if you will — the bloom is off the rose,” said Sol Waksman, founder and president at fund tracker BarclayHedge.

The superstars include John Paulson, who rocketed to stardom after successfully betting on the collapse of the US housing market.

Now the tide has turned. After some bad bets on gold and pharmaceutical stocks, Paulson & Co. has reportedly seen its assets plunge by $6 billion since the end of 2015 due to losses and withdrawals. The firm declined to comment.

In March, Eton Park Capital Management, run by Eric Mindich, announced it was closing and returning capital to investors.

That fund, once holding $14 billion in assets, had reportedly seen that figure whittled down to $7 billion following some bad stock gambles.

Not surprisingly, hedge funds are on a war footing to protect their vital interests.

There may be more at stake than basic survival. As clients look for scalps, one New York-based securities industry lawyer is predicting a record year for hedge fund lawsuits.

“I am seeing some patterns,” Jake Zamansky told The Post. “We are seeing hedge fund advisers misrepresenting the performance of funds, becoming reckless to try and seek alpha or beat the market, doing things outside the investment guidelines. In baseball terms, many hedge fund managers are swinging for the fences and striking out.”