President Trump has long had ties to the nation’s major media players. But his connections with the country’s largest tabloid publisher, American Media Inc., run deeper than most.

A former top executive of Mr. Trump’s casino business sits on A.M.I.’s four-member board of directors, and an adviser joined the media company after the election. The company’s chairman, David J. Pecker, is a close friend of the president’s.

And in the Trump era, A.M.I.’s flagship tabloid, The National Enquirer, has taken a decidedly political turn, regularly devoting covers to the president’s triumphs and travails with articles headlined “Trump’s Plan For World Peace!” and “Proof! FBI Plot to Impeach Trump!”

Since the early stages of his campaign in 2015, Mr. Trump, his lawyer Michael D. Cohen and Mr. Pecker have strategized about protecting him and lashing out at his political enemies.