Television host Megyn Kelly is leaving her position at Fox News for a new broad role at NBC, NBC News announced Tuesday afternoon.

Kelly currently hosts "The Kelly File" on the Fox News Channel in primetime immediately after "The O'Reilly Factor." She started at Fox News 12 years ago and has since risen to stardom, becoming the cable network's second-most watched host–after Bill O'Reilly.

Kelly's role at NBC News will be multifaceted. She will host a new one-hour daytime program that will air Monday through Friday at a time to be announced, a Sunday night news magazine program, and she will "become an important contributor to NBC's breaking news coverage as well as the network's political and special events coverage," according to the announcement.

Fox News is said to have offered Kelly approximately $20 million a year to stay at Fox, an amount that no other network said they could compete with, the New York Times reported. However, the NBC position does have some benefits that Kelly was looking for, including being able to see her children off to school in the morning and spend time with them after school during the week.

Kelly was one of the women who came forward and accused longtime Fox News chief executive Roger Ailes of sexual harassment. She also was the target of many attacks by Donald Trump during his presidential campaign, especially during the Republican primary. Kelly has said that she received many threats afterward from Trump supporters. Trump and Kelly have met since then and said that their relationship is better.

"Megyn is an exceptional journalist and news anchor, who has had an extraordinary career," Andrew Lack, chairman of the NBCUniversal News Group, said of Kelly joining NBC. "She's demonstrated tremendous skill and poise, and we're lucky to have her."

Kelly released a statement shortly after NBC announced her decision to join the network.

"While I will greatly miss my colleagues at Fox, I am delighted to be joining the NBC News family and taking on a new challenge," Kelly said. "I remain deeply grateful to Fox News, to Rupert, Lachlan and James Murdoch, and especially to all of the FNC viewers, who have taught me so much about what really matters."

—@megynkelly posts statement on Facebook: "I have decided to end my time at FNC" https://t.co/wieliv6LhQ pic.twitter.com/EuhaxKICRI — Oliver Darcy (@oliverdarcy) January 3, 2017

UPDATE: 1:38 P.M.: This post was updated to include Megyn Kelly's statement on her decision to leave Fox News for NBC News.