“We thank Megyn Kelly for her 12 years of contributions to Fox News,” the statement read. “We hope she enjoys tremendous success in her career and wish her and her family the best.”

Though the loss of Ms. Kelly is a blow to Fox News, the network has a winning formula that has kept it atop the ratings for many years, and helped it to avoid the fall-offs its rivals experienced in the weeks after Election Day, as The Associated Press reported. And now the nation has a new Republican president whose approach speaks to the sensibilities of many of Fox’s viewers.

Company executives said the Murdochs knew Ms. Kelly was a flight risk; their offer included keeping her in prime time, and she had made it clear she was seeking a job that would give her more time for her family.

Ms. Kelly had spoken with top executives at ABC News, CNN and in the syndication industry, as well as NBC News, but NBC remained largely under the radar as a landing spot. One person briefed on Ms. Kelly’s deliberations said that Mr. Lack won her over by starting the talks with a question about what she was seeking, instead of flatly offering possibilities.

He then came back with a deal that was tailored to her preferences. A daytime show would give her a schedule that would allow her to see her children off to school and to have dinner with them and her husband, Douglas Brunt, a novelist.

People briefed on the talks, who spoke on the condition of anonymity, declined to disclose what Ms. Kelly’s new annual salary would be at NBC. Fox News rivals who sought to hire Ms. Kelly away, including NBC News, had indicated that they could not match the $20 million offer from Fox, the cable news leader for the last 15 years running.

But even a modest raise for Ms. Kelly would place her among television’s highest-paid journalists. The Wall Street Journal recently reported she was to collect $15 million for the final year of her contract.