The US government has issued a travel warning advising US citizens to leave Saudi Arabia.
More than 50 people were killed last year in two separate attacks
The warning said US officials had received recent and credible information that terrorist attacks were being planned in the country.
All non-essential US diplomats and all diplomats' family members have been ordered to leave, and private citizens are strongly urged to depart.
This is the third such evacuation in the country since last November.
US citizens who remain in the country despite the warning are being asked to register at the embassy in Riyadh or at the Jeddah or Dhahran consulates.
They are asked to remain vigilant, especially in public places associated with Westerners.
More than 50 people were killed last year in two separate attacks against compounds housing foreigners.
On Wednesday, at least one member of the Saudi security forces was killed and another wounded when gunmen attacked their patrol north of Riyadh.
A day earlier, suspected Muslim militants killed four Saudi policemen in separate incidents north of the capital.
Officers were shot at a checkpoint on the road to Qassim province after ordering a car to stop. The attackers fled in two stolen police cars.
Police said the men had probably been involved in a gun battle in Riyadh on Monday in which one suspected militant and one police officer died.
Police also defused two car bombs and seized a third car full of arms.
"The terrorists had packed a huge quantity of explosives in the cars and they would have caused major damage," a security source told Reuters.
Non-essential diplomats were told to leave Saudi Arabia in December after the US government said it received "indications of terrorist threats aimed at American and Western interests".
The threats were said to included the targeting of civil aviation and other transport.
In November, the Riyadh embassy shut just hours before a suicide bomb blast - blamed on al-Qaeda - killed 18 people and injured more than 100 in the city.