Two Silicon Valley billionaires with a history of bad blood are squaring off over Gawker.

Pierre Omidyar, an eBay co-founder, is leading the charge to support Gawker in its appeal of a $140 million judgment awarded to Hulk Hogan, whose lawsuit was bankrolled by rival billionaire and PayPal co-founder Peter Thiel, The Post has learned.

Omidyar’s First Look Media, the online news venture that includes The Intercept, is reaching out to other media organizations to file friend-of-the-court briefs in support of Nick Denton’s Gawker, which could be bankrupted by the Hogan judgment.

“First Look Media is looking into organizing amicus support for Gawker in its legal fight and appeal against Hulk Hogan,” Lynn Oberlander, First Look’s general counsel, exclusively told The Post.

By filing the amicus briefs in support of Gawker, First Look could effectively elevate the trial into a First Amendment rights case by pitting Thiel against dozens of media organizations — many of which are owned by other billionaires.

First Look has expressed support before for Gawker, but that was before Thiel’s involvement in the case was revealed this week in a Forbes story. Now there is renewed interest on Omidyar’s part, sources said.

The history between the two billionaires goes back more than a decade, when Omidyar’s eBay first purchased PayPal, which Thiel co-founded with Elon Musk, the Tesla Motors entrepreneur.

Omidyar, worth about $7.7 billion, is a crusading liberal and philanthropist who doesn’t see eye to eye with Thiel, a free-market libertarian who backs Donald Trump’s bid for the presidency.

“So Thiel agrees with Trump’s plan to muzzle press that criticizes government, obviously. That’s why he supports him?” Omidyar tweeted on Wednesday.

“Obviously there’s bad blood between Omidyar and Thiel,” one source told The Post.

Thiel, worth an estimated $2.7 billion, has provided about $10 million to fund the invasion-of-privacy suit filed by Hogan. A Florida jury sided with the wrestling legend in March.

Hogan, whose real name is Terry Bollea, sued Gawker for posting a video of him having sex with the wife of his best friend at the time. This week, Gawker lost a motion to get the verdict thrown out.

Gawker’s lawyers have said the size of award — which was even more than Hogan asked for — could prove “ruinous” to the company.

The Post first reported on Thursday that Gawker founder Denton hired investment bank Houlihan Lokey to advise him on the valuation of the cash-hungry company in the event that he needs to sell it to pay damages to Hogan.