A hand grenade-shaped belt buckle tucked inside a suitcase triggered train station evacuations and widespread rail service disruptions in two of Spain’s largest cities Wednesday.

Spanish police said a security scanner at Barcelona’s Sants railway station flagged an object inside a woman’s suitcase that resembled an explosive device, triggering the security alert.

The incident turned out to be a false alarm, however, and officials determined the object didn't pose any danger.

Authorities in Barcelona say the city's main train station has re-opened after it closed for more than one hour at Wednesday's rush hour while police searched for possible explosives in a suspicious suitcase. (AP Photo/Joan Monfort)

The Catalan regional police force -- the Mossos d’Esquadra -- said an explosives unit was dispatched to the train station during the scare.

A photograph released by the force appeared to show the outline of a hand grenade in a suitcase. But the nefarious-looking object turned out to be a belt buckle.

The security alert also led to the evacuation of Madrid’s Atocha station while police investigated.

“Our officers have carried out the appropriate checks at Madrid’s Atocha station and found it was a false alarm,” Spain’s national police said in a tweet. “The police operation is over and everything is back to normal.”

Spain's railway infrastructure managing company, ADIF, which handles security in train stations, didn't immediately respond to questions about why the suspicious case was allowed onto the train.

Atocha station in Madrid was the site of a March 2004 terror attack that killed 193 people and wounded about 2,000 - Spain’s deadliest militant attack. Police said it was carried out by Islamist militants inspired by Al Qaeda.

A homegrown extremist cell used vehicle and knife attacks to kill 16 people in Barcelona and a nearby coastal resort in 2017. The plot was later claimed by ISIS.

The Associated Press contributed to this report.