Bill O’Reilly’s reign as the top-rated host in cable news came to an abrupt and embarrassing end on Wednesday as Fox News forced him out after the disclosure of a series of sexual harassment allegations against him and an internal investigation that turned up even more.

Mr. O’Reilly and his employers came under intense pressure after an article by The New York Times on April 1 revealed how Fox News and its parent company, 21st Century Fox, had repeatedly stood by him even as he and the company reached settlements with five women who had complained about sexual harassment or other inappropriate behavior by him. The agreements totaled about $13 million.

Since then, more than 50 advertisers had abandoned his show, and women’s rights groups had called for him to be fired. Inside the company, women expressed outrage and questioned whether top executives were serious about maintaining a culture based on “trust and respect,” as they had promised last summer when another sexual harassment scandal led to the ouster of Roger E. Ailes as chairman of Fox News.

That left Mr. O’Reilly’s fate in the hands of the Murdoch family, which controls 21st Century Fox. In the end, according to two people familiar with the decision, Rupert Murdoch and his sons, James and Lachlan, made their decision after reviewing the results of an internal investigation that found multiple women had reported inappropriate behavior by Mr. O’Reilly.

“After a thorough and careful review of the allegations, the company and Bill O’Reilly have agreed that Bill O’Reilly will not be returning to the Fox News Channel,” 21st Century Fox said in a statement.

During an appearance at an event in New York on Wednesday evening, James Murdoch stopped to answer a question about the decision, saying: “We did a thorough investigation, a thorough review, and we reached a conclusion. Everything that we said in our statement is all you need to know.”

For a generation of conservative-leaning Fox News viewers, Mr. O’Reilly, 67, was a populist voice who railed against what they viewed as the politically correct message of a lecturing liberal media. Defiantly proclaiming his show a “No Spin Zone,” he produced programming infused with patriotism and a scorn for feminists and movements like “The War on Christmas,” which became one of his signature themes.

The news of Mr. O’Reilly’s ouster came as he was on a vacation to Italy, where on Wednesday morning he met Pope Francis at St. Peter’s Square in the Vatican. Mr. O’Reilly’s tickets to the Vatican were arranged by Cardinal Timothy M. Dolan, the archbishop of New York.

In a statement later in the day, Mr. O’Reilly praised Fox News but said it was “tremendously disheartening that we part ways due to completely unfounded claims.”

“But that is the unfortunate reality many of us in the public eye must live with today,” he said. “I will always look back on my time at Fox with great pride in the unprecedented success we achieved and with my deepest gratitude to all my dedicated viewers. I wish only the best for Fox News Channel.”

Mr. O’Reilly’s departure is the latest development in a tumultuous nine months at Fox News. In the aftermath of Mr. Ailes’s dismissal in July, the Murdochs pledged to clean up the network’s culture. But since then, it has been hit with new sexual harassment allegations, and female staff members said they remained fearful of reporting inappropriate behavior.

Mr. O’Reilly’s dismissal was hailed by women’s rights activists and some inside the company as a sign that the network, and perhaps corporate culture at large, was finally taking the issue of sexual harassment seriously.

“This is a seismic cultural shift, when a corporation puts a woman’s rights above the bottom line,” said Wendy Walsh, a former guest on Mr. O’Reilly’s show, “The O’Reilly Factor,” who made allegations against him. “Today, we have entered a new era in workplace politics.”