The United States announced Thursday it is pulling out of the U.N.'s educational, scientific and cultural agency because of what Washington sees as its anti-Israel bias and a need for "fundamental reform" in the agency.

Israeli Prime Minister Benjamin Netanyahu said Israel plans to follow suit.

While the Trump administration had been preparing for a likely withdrawal from UNESCO for months, the timing of the State Department's statement Thursday was unexpected. The Paris-based agency is in the midst of a heated election to choose a new chief — with Qatar's Hamad bin Abdulaziz al-Kawari in the lead as the Executive Board vote heads into a final ballot on Friday.

The outgoing UNESCO director-general, Irina Bokova, expressed her "profound regret" at the U.S. decision and tried to defend the reputation of the U.N. Educational, Scientific and Cultural Organization, best known for its World Heritage program to protect cultural sites and traditions.

She called the U.S. departure a loss for "the United Nations family" and for multilateralism, saying the U.S. and UNESCO matter to each other more than ever now to better fight "the rise of violent extremism and terrorism."

The U.S. stopped funding UNESCO after it voted to include Palestine as a member state in 2011, but the State Department has maintained a UNESCO office and sought to weigh in on policy behind the scenes. The U.S. now owes about $550 million in back payments.

In a statement, the State Department said the decision will take effect Dec. 31, 2018, and that the U.S. will seek a "permanent observer" status instead. It cited U.S. belief in "the need for fundamental reform in the organization."

Netanyahu said Thursday that Israel also plans to withdraw from the agency, saying it had become a "theater of the absurd because instead of preserving history, it distorts it."

Israel has been irked by resolutions that diminish its historical connection to the Holy Land and have instead named ancient Jewish sites as Palestinian heritage sites.

Praising Trump's decision as "brave and moral," Netanyahu said he has ordered Israeli diplomats to prepare for Israel's withdrawal from the organization in concert with the Americans.

Israel's ambassador to the United Nations, Danny Danon, also praised Washington's move as heralding "a new day at the U.N., where there is a price to pay for discrimination against Israel."

"UNESCO has become a battlefield for Israel bashing and has disregarded its true role and purpose," Danon said.

U.S. officials said Secretary of State Rex Tillerson made the decision and it was not discussed with other countries. The officials, who were not authorized to be publicly named discussing the issue, said the U.S. was notably angry over UNESCO resolutions denying Jewish connections to holy sites and references to Israel as an occupying power.

Chris Hegadorn, the U.S. Charge d'Affaires and ranking U.S. representative to UNESCO, told The Associated Press on Thursday that the decision to pull out was linked to "the unfortunate politicization of the mandate of UNESCO, where anti-Israel bias has been a major factor and something the U.S. has been struggling to address."

Many saw the 2011 UNESCO vote to include Palestine as evidence of long-running, ingrained anti-Israel bias within the United Nations, where Israel and its allies are far outnumbered by Arab countries and their supporters.

UNESCO chief Bokova defended her agency's reputation, noting its efforts to support Holocaust education and train teachers to fight anti-Semitism — and saying that the Statue of Liberty is among the many World Heritage sites protected by the U.N. agency. UNESCO also works to improve education for girls in poor countries, help them enter scientific fields, defend media freedom and coordinate world knowledge about climate change, among other activities.

UNESCO's executive board plans to select her successor Friday in a secret ballot.

It's not the first time the U.S. has pulled out of UNESCO: Washington did the same thing in the 1980s because it viewed the agency as mismanaged, corrupt and used to advance Soviet interests. The U.S. rejoined it in 2003.

Hegadorn said the U.S. would remain a force at the cultural agency in the same way as it was from 1984, when the country withdrew under then-President Ronald Reagan.

The U.S. told Bokova it intends to stay engaged as a non-member "observer state" on "non-politicized" issues, including the protection of World Heritage sites, advocating for press freedoms and promoting scientific collaboration and education.

"We will be carefully watching how the organization and the new director general steers the agency," Hegadorn said. "Ideally, it steers it in way that U.S. interests and UNESCO's mandate will converge."

Lee reported from Washington. Edie Lederer in New York, Aron Heller in Jerusalem and Angela Charlton in Paris contributed to this report.