An explosive lawsuit accusing the country’s biggest private-equity firms of conspiring to drive down prices on deals is moving forward after surviving its biggest legal challenge yet.

A federal judge in Boston denied a motion to dismiss the antitrust case — which accuses 10 buyout firms of costing shareholders billions by keeping prices artificially low — while narrowing the scope of the claims.

The PE firms, including Apollo Global Management, Bain Capital, Blackstone Group, Carlyle, KKR and a unit of Goldman Sachs, have tried nearly a dozen times in four years to get the suit tossed.

In his ruling yesterday, Judge Edward Harrington said shareholders could pursue their claim that the firms agreed not to jump each other’s exclusive deals. The only defendant he released from the count was JPMorgan Chase.

He also allowed a separate count to proceed alleging that Bain, KKR and Merrill Lynch paid an artificially low price in the $32 billion buyout of the HCA hospital chain in 2006.

Each count could result in billions of dollars in damages, according to sources on both sides of the case.

However, Harrington dismissed the charge that the firms decided who would be the exclusive bidder as part of an overarching conspiracy involving 27 deals. His decision will limit the remaining case to eight takeovers.

“While some groups of transactions and defendants can be connected by ‘quid pro quo’ arrangements, correspondence, or prior working relationships, there is little evidence in the record suggesting that any single interaction was the result of a larger scheme,” Harrington wrote.

In allowing the charge of not jumping announced deals to proceed, the judge appeared to be swayed by several “silver bullet” e-mails.

One e-mail from Neil Simpkins of Blackstone Group to colleague Joseph Baratta said, “The reason we didn’t go forward [with a rival HCA bid] was basically a decision on not jumping someone else’s deal.”

Baratta said, “I think the deal represents good value and it is a shame we let KKR get away with highway robbery, but understand decision.”

Another frustrated Blackstone executive writing about passing on the deal said, “We are a bunch of p**s*es.”

KKR’s $1.2 billion investment in HCA has nearly doubled in value to $2 billion in four years.

Ironically, Bain and KKR, which bought HCA, are released from claims by settling an earlier shareholder suit. So any damages from the HCA count would fall to those who considered bidding but dropped out — Blackstone, Carlyle, TPG Capital and Goldman Sachs.

The private equity firms can ask for a new summary judgment hearing over the eight remaining buyouts.

The defendants will likely ask for that new hearing, which would be scheduled in about six months.

If the cases go to trial, the plaintiffs are expected to call some of the biggest names in the PE world, including Apollo’s Leon Black, KKR’s Henry Kravis and Blackstone’s Steve Schwarzman.

Lawyers for both sides declined comment.