They were the latest in a string of suspects seized in Ceuta and Spain's other north African territory, Melilla, where authorities have been monitoring suspected extremist cells.
Police searched two properties in the dawn raids that yielded the arrests, the interior ministry said in a statement.
"They are investigating whether those arrested, who formed a cell, had the infrastructure to carry out an attack on our national territory," it said.
It made no link between today's arrests and an ongoing investigation into suspects linked to this month's deadly Islamist attacks in Paris and other foiled plots in Belgium, some of whom are said to have travelled to Spain.
It said today's operation was ongoing and it would release further details of the raids later.