Interior Ministry spokesman Mansour al-Turki said in a statement on Sunday that 26 of the detainees were foreigners, including 16 Syrians.
Turki added that in addition to the 16 Syrians, the detained foreign suspects included three from Yemen, an Egyptian, a Lebanese, an Afghan, an Ethiopian, a Bahraini, an Iraqi and a stateless person.
He says the suspects were arrested in different parts of Saudi Arabia, though he did not say when.
Some of the men allegedly received weapons training, fought as militants in conflicts abroad and had been planning to carry out attacks. Others are accused of smuggling weapons into Saudi Arabia, and helping to raise money and recruit for terrorist organizations.
He says 17 men were detained for suspected links to attacks against security forces in the Eastern Province, where minority Shiites are centered.