"There is no longer any evidence suggesting that the accused were jihadists," Judge Santiago Pedraz wrote in a ruling.
Police regularly announce the detention of suspected jihadists accused of propaganda or glorifying extremism, but this particular arrest late December caused alarm as information emerged suggesting that both men were actively considering an attack.
Police said they had found videos showing a man in front of the Islamic State flag shouting "Allah is great" and other men holding an AK-47.
Authorities were quick to allay fears, saying there was no indication an attack was actually being organised before the arrest, but the discovery still sparked jitters in the capital.
Then Spanish media reported that the suspects were the victims of a scheme initiated by a police informant dubbed "Lolo."
The El Mundo daily reported last week that the video was put together by "Lolo", who was paid monthly by the police and would get a bonus for "extraordinary" information.
Madrid's police, though, took him at his word and launched the probe that led to the arrests, it added.
In his ruling, the judge confirmed that "Lolo" was an informant.
He added that nothing, not even phone taps, pointed to "the possible existence of a terrorism offence."
The AK-47 seen in the videos was never found, and it is not even certain that it was real, the judge said.
But he only let the two men out on conditional release pending the analysis of all items seized during the probe.
Disclaimer: No Business Standard Journalist was involved in creation of this content
You’ve reached your limit of {{free_limit}} free articles this month.
Subscribe now for unlimited access.
Already subscribed? Log in
Subscribe to read the full story →
Smart Quarterly
₹900
3 Months
₹300/Month
Smart Essential
₹2,700
1 Year
₹225/Month
Super Saver
₹3,900
2 Years
₹162/Month
Renews automatically, cancel anytime
Here’s what’s included in our digital subscription plans
Exclusive premium stories online
Over 30 premium stories daily, handpicked by our editors


Complimentary Access to The New York Times
News, Games, Cooking, Audio, Wirecutter & The Athletic
Business Standard Epaper
Digital replica of our daily newspaper — with options to read, save, and share


Curated Newsletters
Insights on markets, finance, politics, tech, and more delivered to your inbox
Market Analysis & Investment Insights
In-depth market analysis & insights with access to The Smart Investor


Archives
Repository of articles and publications dating back to 1997
Ad-free Reading
Uninterrupted reading experience with no advertisements


Seamless Access Across All Devices
Access Business Standard across devices — mobile, tablet, or PC, via web or app
