Mr. O’Brien took the program to Haiti after Mr. Trump disparaged that country, speaking with schoolchildren there about how the presidential insult made them feel. More recently, he traveled with his camera crew to Greenland after Mr. Trump floated the idea of buying it.

In addition to providing a ratings boon, an emphasis on politics wins accolades. HBO’s “Last Week Tonight With John Oliver,” a show that is as much journalism as it is comedy, has won the Emmy for outstanding variety talk series four years in a row. And with the 2020 campaign heating up, the presidential candidates Joseph R. Biden Jr., Elizabeth Warren, Bernie Sanders, Beto O’Rourke, Pete Buttigieg, Kamala Harris and Cory Booker have all made the late-night rounds.

“If you’re a candidate now and you’re not on one of these shows or discussed by one of these hosts, you are not alive,” said Hank Sheinkopf, a veteran Democratic political consultant.

Hollywood stars are still staples of late night. “If I could have Tom Hanks every night, I would get him,” Mr. Licht said. Will Smith scored 3.9 million viewers for his recent appearance on Mr. Colbert’s show, and James Corden, the host of CBS’s “The Late Late Show,” has lately led the 12:30 a.m. time slot in total viewers with a program that often has the feel of a celebrity clubhouse.

But Mr. Corden’s rival Seth Meyers, the host of NBC’s “Late Night With Seth Meyers, ” drew more total viewers in the 2018-19 season thanks to a formula that had him devoting the first 20 minutes of his show to the latest on Mr. Trump. Mr. Meyers also led among adult viewers under 50 last season, and he remains the leader among that segment of the audience.

In this supercharged news environment, anchors like Bret Baier and Chris Wallace, both of Fox News, have been late-night guests, as have the CBS News stalwarts Gayle King and Norah O’Donnell. When Ms. King and Ms. O’Donnell were the lead guests on Mr. Colbert’s live show after the State of the Union address in February, they drew an audience of 4.6 million.

Jay Sures, a co-president of the United Talent Agency, which represents many news anchors, said he had noticed a spike in bookings for his clients. “They’ve unintentionally become celebrities based on how the news business has become part of our daily routine in a way it never has before,” he said. “The Trump era has elevated news.”