It also helped that Mr. Miliband and Richard Plepler, chairman and chief executive of HBO, know each other.

“When I heard of the challenges of the I.R.C., I had lunch with him and told him that we’re here to help,” Mr. Plepler said.

HBO’s creative services team filmed the public service announcement, and Omaze also plans to release three videos for its site that will take a lighter tone: The first is called “Swords vs. Metal Bands.” The campaign will include another public service announcement and related content later in the season, to be released on social media and the International Rescue Committee’s website.

Cause-marketing can backfire, however. When KFC partnered with the Susan G. Komen Foundation, which raises money for breast cancer research, the company was criticized for “pinkwashing” because eating deep-fried chicken can contribute to obesity, and obesity has been linked to an increased risk of breast cancer in postmenopausal women.

Even Toms, the shoe company known for its involvement in good causes, received pushback on its “One for One” campaign — donating a pair of shoes to children around the world for every pair bought. Critics said such donations could undercut local shoe sellers, and make people reliant on outside aid.

Steve McKee, president of the ad agency McKee, Wallwork and Company, who has written about cause-related advertising, emphasized that he was not familiar with the “Game of Thrones” campaign, but noted that “if the cause is controversial in any way — if there are two legitimate sides to the issue — you’re really playing with fire. The trust you build with some may be lost with others.”

The first “Game of Thrones” public service announcement avoids politics; it mentions, for example, the thousands of refugees granted safe haven in the United States, but not the debate about whether countries, including the United States, are accepting enough or too many refugees.