In a 4am (0200 GMT) operation, officers dismantled an international network that was recruiting and sending out jihadists to join "terrorist organizations" based in Mali and Libya, the Spanish interior ministry said in a statement.
"Up to now six people have been arrested and there are eight searches underway," the ministry said.
"Among those arrested is the first Spanish jihadist returned from the conflict in Mali after passing through training camps held by the Movement for Oneness and Jihad in West Africa (MUJAO) in that territory," it said.
MUJAO is an Al-Qaeda splinter group operating in Mali. Last month, a spokesman for the group told AFP that a French hostage it had taken in November 2012, 62-year-old Gilberto Rodrigues Leal, "is dead because France is our enemy".
The Spanish police operation, carried out under the supervision of an investigating judge and the National Court prosecutor, remained open, the
In a separate raid on March 14 this year, Spanish and Moroccan forces broke up another suspected jihadist cell with members in Melilla, which is one of two Spanish-governed cities along with Ceuta on the northern Morocco coast.
The authorities detained three people in Morocco and another four in Spain, among whom one was caught in the southern city of Malaga and the other three in Melilla.
That cell was suspected of sending volunteer fighters to Mali, Syria and Libya.
Morocco was threatened with attacks last year in a video message by the regional extremist network Al Qaeda in the Islamic Maghreb.
Spain's government has said it fears battle-hardened Islamist fighters may return to Spain from Syria and other conflict zones under the influence of Al-Qaeda-inspired groups, presenting a threat of attacks.
Spain this year marked the 10th anniversary of the March 11, 2004 Al-Qaeda-inspired bombing of four packed commuter trains in Madrid, which killed 191 people.
Since the Madrid train bombings, more than 470 suspected Islamic extremists have been arrested in Spain, according to the Spanish interior ministry.