A man with extreme homophobic and racist views made a 9kg (19lb) fertiliser bomb and other explosive devices in his flat, a court heard.
Police raided Steven Bracher's home in Devon in January and found three pipe bombs and 17 other improvised devices.
Bracher, 55, admitted three counts of having explosive substances, one of possessing a lock-knife and one of possessing amphetamines
He was remanded in custody by a judge at Exeter Crown Court.
Judge David Evans ordered psychiatric and probation reports and adjourned the case until 8 June.
Bracher's flat in Law Memorial Houses, Bishop's Tawton, was raided on 24 January after he was arrested carrying a knife in Barnstaple High Street.
As well as explosives, police found "jottings" expressing racist and homophobic views and a desire to kill people.
After the raid, Royal Navy explosives experts spent several hours removing a large quantity of chemicals from the flat.
The largest bomb was a device made from ammonium sulphate and diesel oil which was found under his bed.
A controlled explosion, filmed as evidence, left a large hole in the ground.
'No terrorism links'
Judge Evans said: "We have someone who may be labouring under some sort of mental health problem, who is addicted to a drug which may have unpredictable side-effects and who was expressing these intentions and desires.
"Metaphorically, it is an explosive mixture."
David Sapiecha, prosecuting, said the situation could have "turned quite nasty" but there were no links to terrorism.
"The property was full of weaponry including machetes, knives and things like that. There were jottings which show fairly nasty views with regard to sections of society," he said.
Defence barrister Richard Crabb, said Steven Bracher had no psychiatric history and there was no indication he had any intention to harm anyone or to damage property.