President Trump is poised to lose yet another battle over a big media merger that he hates.

The Department of Justice has decided against ramping up an investigation into Comcast’s seven-year-old acquisition of NBCUniversal — despite Trump recently doubling down on his criticism of the tie-up as anticompetitive, The Post has learned.

The DOJ said in August it was still monitoring Comcast’s activities even though a consent decree in which it agreed not to withhold NBC programming from rival cable companies or video streaming services was expiring in September.

Nevertheless, federal prosecutors have failed to file a so-called civil investigative demand for company records that would mark a stepped-up investigation and have no plans to do so — effectively clearing the regulatory cloud that has long hung over the deal, according to sources.

“Nothing is happening,” a source close to Comcast said. “I think if the DOJ were going to take action, it would have happened by now.”

Neither Comcast nor the DOJ responded to requests for comment Thursday.

The DOJ is backing off partly because it fears it wouldn’t get a favorable hearing from US Judge Richard Leon, who approved the merger in 2011, sources said. That’s because Leon appears miffed over the DOJ’s recent appeal of his June approval of AT&T’s merger with Time Warner — a deal which, also against Trump’s wishes, allowed the companies to retain ownership of CNN.

The tide appeared to turn late last month, when Leon ordered a surprise delay of the CVS-Aetna merger into next summer, castigating DOJ officials for not policing the deal more aggressively.

Just two weeks earlier, momentum had appeared to be building for the DOJ to move against Comcast, whose NBC division’s “Saturday Night Live” has drawn barbs from Trump over Alec Baldwin’s mugging impersonations of him.

On Nov. 12, the American Cable Association, which represents more than 700 smaller video and broadband providers, asked the DOJ to open an investigation into Comcast. That prompted Trump to tweet that the trade group said Comcast “routinely violates Antitrust laws.”

Trump has a history with NBC that some insiders argue is even more bitter than his feud with CNN. On top of Baldwin’s weekly insults, NBC in 2015 ended its partnership with Trump to air the Miss USA and Miss Universe pageants after the presidential candidate vowed to stop “rapists” and “criminals” from Mexico from coming to the US.

On the campaign trail, Trump said President Barack Obama’s DOJ never should have cleared the Comcast-NBC merger.

Comcast, meanwhile, has been slapped repeatedly for anticompetitive behavior. In 2012, the Federal Communications Commission investigated Comcast for not offering customers a reasonably priced broadband option if they didn’t want cable. The agency ended up extending a protective order governing the Comcast-NBCU merger by a year.

A year later, the FCC sided with Bloomberg TV when it sued Comcast for exiling the business news channel to the far end of the menu in order to benefit CNBC. News reports in 2013 also alleged that Comcast — which as part of its DOJ consent decree was supposed to be only a passive investor in Hulu — stopped Hulu from selling itself to rival DirecTV by cutting a deal to invest more in the streaming service.

Friction with Leon aside, the DOJ may have other reasons for giving up on Comcast, said Jonathan Rubin, an antitrust attorney at MoginRubin.

“I could see the DOJ saying, ‘We really don’t feel like the conditions placed on the NBC merger were effective and they are hard to implement,’” so why extend an ineffective settlement? Rubin said.