But the charges of belonging to an armed group remained against the five, who must surrender their passports and report to the authorities daily, a court official said during Wednesday's trial.
The suspects are four Syrians and one Algerian, Aljazeera's correspondent in Spain reported.
Four were released on bail ranging from $24,558 to $184,149, and the fifth was released without bail.
They are among 24 men on trial for belonging to al-Qaida, seven of whom have been released, including Aljazeera correspondent Taysir Alluni.
The court went by several criteria
for allowing the temporary release
One of the suspects was released on bail because the main evidence against him was not considered strong enough, Alluni reported.
He was accused of giving videotapes he had taken in New York in 1997 to al-Qaida before the 11 September 2001 attacks.
But the court was convinced that the videotapes were filmed only for tourism and had no links to the 11 September attacks.
Two others had been conditionally released, including one of the three defendants accused of collaborating in the 11 September attacks.