A Spanish Interior Ministry statement said police detained the eight in Madrid early Monday on suspicion of recruiting jihadi militants for the Islamic State of Iraq and the Levant, or ISIL.
It said the cell was led by a person who live in Spain but had previously been jailed in Guantanamo Bay after being arrested in Afghanistan in 2001.
Spain gave no immediate details on the nationalities of the arrested.
In Berlin, prosecutors' spokesman Martin Steltner said police on Saturday arrested a 30-year-old Frenchman suspected of "supporting a terrorist organization" by fighting in Syria for the group.
More From This Section
A court will decide on his extradition to France in the coming weeks.
The French Interior Ministry said in a statement that the detainee had been identified by French intelligence agency DGSI as "dangerous and susceptible of acting on French soil." The statement said he was arrested upon arrival from Istanbul. German police also arrested a 27-year-old German woman at Frankfurt airport on Thursday, and a 17-year-old German in Stuttgart on Friday. Both are being linked to Islamist extremist groups.
The suspect in that shooting passed through Frankfurt airport earlier this year, triggering an alert from German authorities to their French colleagues but they didn't ask for his arrest.