A seventh al-Qaeda suspect was wounded and captured in the dawn shootout in al-Nakhil neighbourhood of the capital, an interior ministry spokesman said in a statement, adding that other members of the security service were wounded.
"The security forces at dawn on Friday pursued seven ... members of the deviant minority to a house in the Al-Nakhil district of Riyadh ... where they suddenly came under sustained automatic weapons fire," the spokesman said.
The police "managed to take control of the situation quickly, killing six of them, wounding and capturing the seventh," he said.
"A member of the security forces was killed and others were wounded in the operation."
The term "deviant minority" is used in Saudi official language to designate the local branch of al-Qaeda, responsible for a wave of violence in the kingdom since May 2003.
One of the officers cordoning off the area where the clash took place told AFP: "The group was preparing a terrorist operation and its members were being tailed on the basis of intelligence service information."
Residents of al-Nakhil told AFP the clash started shortly before 2.30am (2330 GMT on Thursday) around a villa.
"Some armed men who had barricaded themselves in the villa tried to escape but the security forces fired at them, destroying their car," said one witness.
Fighting broke out about 2.30am
in Riyadh's al-Nakhil area
The shooting lasted about half an hour.
Residents said a police helicopter was called in to help with the operation, and that they had seen at least 11 wounded police being taken away.
Police could be seen taking cardboard boxes stuffed with documents and computer equipment out of the villa after the operation, an AFP correspondent said.
Saudi King Abdullah pledged in April to annihilate al-Qaeda-linked militants in the kingdom.
Saudi Arabia has been under pressure to crack down on militancy since the September 11 attacks on the United States, a strike masterminded by Saudi-born Osama bin Laden, in which 15 out of the 19 suicide hijackers were Saudi.