The State Department is advising nonessential U.S. diplomats to leave Saudi Arabia, Qatar and Bahrain. The advice is based on anti-American sentiment in the region, a U.S. official said Wednesday.

All three countries are expected to play supporting roles in the event of a U.S. military campaign in Iraq.

Family members of U.S. diplomats in Qatar and Bahrain were also advised to depart. The government will pay for their travel home as well as for departing diplomats in all three countries.

Family members of U.S. diplomats in Saudi Arabia had already been advised to leave the country.

Last year, the department spent more than $2.6 million to evacuate 13 diplomatic posts overseas for security reasons. The year before, it cost more than $3 million to evacuate 16 posts, and in 2000 eight posts were evacuated at a cost of $565,369, the department said.

In what is called an authorized departure, the department advises -- but does not compel -- nonessential diplomats and the families of diplomats to leave a country.

The department pays the airfare and daily living expenses.

Last Friday, the department advised nonessential U.S. diplomats and family members to leave Israel, Jordan, Syria and Lebanon. Private U.S. citizens also were advised to leave those countries and Americans were cautioned not to travel to Israel.

At the same time, the department urged Americans to stay away from Iraq and said it was closing the Polish office in Baghdad that provided consular service to Americans in the absence of U.S. relations with Iraq.

U.S. citizens in Iraq were urged to leave.

Thousands of Americans, including private citizens, could be involved, department spokesman Richard Boucher said Monday. There are no figures available on how many have chosen to leave and at what cost.