An airport security manager “popped a pipe bomb in her pocket” for safekeeping when security staff found it in a passenger’s hand luggage.
The “crude improvised explosive device” was found in Nadeem Muhammad’s carry-on luggage as he went through security at Manchester Airport on 30 January.
Made from batteries, wire, masking tape and a marker pen tube it was “potentially viable”, the court heard.
Mr Muhammad, 43, denies possessing explosives with intent.
Security terminal boss Deborah Jeffrey told Manchester Crown Court the item had been swabbed and the device showed no trace of explosives so she “put the item into my pocket so it wouldn’t go missing”.
She later put it through an X-ray machine and believed it was not viable because she could not see a detonator.
Counter terrorism police subsequently examined it and found it contained nitroglycerin and nitrocellulose and was “potentially viable.”
Mr Muhammad, who lives on Tinline Street, Bury was born in Pakistan and holds an Italian passport.
He was attempting to board a Ryanair flight to Bergamo in the Lombardy region of northern Italy when the item was discovered.
Ms Jeffrey said: “There are strange things people carry in their bags but I’d not seen anything like that before.”
She said she had asked Mr Muhammad how the object came to be in his case and he claimed someone else might have put it there.
She said he was “very calm and quiet”.
Police questioned Mr Muhammad but did not arrest him. He returned to the airport on 5 February and flew to Italy.
Three days later a forensics officer examined the device and called the bomb squad.
Forensics expert Lorna Philp said the bomb had the potential to cause injury to people and damage to property if detonated.
Get Quotes on Home Insurance
The person setting it off would have had to be very close to the bomb to connect the wires protruding from it though, her report found.
Mr Muhammad was arrested when he returned to the UK on 12 February.
He denies possession of explosives with intent to endanger life or property and an alternative charge of possession of explosives under suspicious circumstances.
The trial continues.