Anwar Driouich, 22, from Middlesbrough, admitted possessing 10kg of ammonium nitrate and seven terrorist manuals, including Munition Black Books, Anarchy Cookbook, Inspire, Ragnar's Big Book Of Homemade Weapons and Bloody Brazilian Knife Fighting Techniques.
He hoarded weapons, including knives and a crossbow, and wrote in Facebook chat he was a "cold-blooded SOB" who wanted to "massacre this place".
The defendant also trawled the internet for mass shootings, terrorist attacks, and "incels" - a term for young men who consider themselves "involuntarily celibate", a loose US online community responsible for high-profile murders and a mass shooting.
However, his lawyer argued Driouich was a not terrorist, had no plans to make a bomb, and made "teenagerish" comments.
Opening the facts, prosecutor Tom Walkling said Driouich was arrested in London last August after the company Aqua Plants Care reported his online order for 10kg of Ammonium Nitrate, a component of high explosives.
Police found he had previously bought online 3.5kg of ammonium nitrate, a knuckleduster, retractable baton, handcuffs, balaclavas, and instructions on making a flamethrower.
An examination of an iPhone revealed his stash of terror manuals and a note, under the password "killer", listing weapons, body armour and tactical equipment, the court heard.
Police searched his home and recovered more precursor chemicals, three knives, a crossbow, bullet moulders, ball bearings and arrow heads.
A Spider-man notebook also contained notes on manufacturing explosive precursors, Mr Walkling said.
In a Facebook chat in March last year, he said: "It feels like there is hardly any point trying now... I want to massacre this place man I wouldn't even feel sorry for anyone.
"I know I'm a cold hearted sob. I just can't help it I have so much anger built up in me."
In mitigation, Lucie Wibberley said Driouich was a "troubled" young man who has been targeted by bullies and struggled to make friends.
He was brought up by his Muslim father after his Jehovah's Witness mother died of cancer when he was aged nine but the "final straw" came when a friend committed suicide, she said.
Driouich had sought help for his mental health problems, which included "intrusive thoughts of violence".
Ms Wibberley stated that her client was not a terrorist and had no affiliation or sympathies with any extremist group.
Via video link from Belmarsh prison, Driouich apologised for his "reckless and foolish behaviour".
Reading a letter to the judge, he said: "I am sorry for the alarm my actions have caused to my community as well as all the police time and energy that has been taken up.
"I am adamant that these offences do not define me as an individual, especially the Tact (terrorist) offences and the thought of being associated with them fills me with revulsion and embarrassment."
Sentencing, Judge Leonard told him: "I accept this is an unusual case but you, Driouich, must understand the serious nature of your behaviour."
Detective Chief Superintendent Martin Snowden, head of Counter Terrorism Policing North East, said: "Whilst there was no evidence of Driouich having a terrorist mindset, there was evidence of his morbid fascination with extreme violence.
"It is possible that he could have gone on to be influenced by others to commit further offences had he not come to the attention of the authorities.
"The materials in his possession could easily be used by those intent on causing harm to others and seeking to disrupt society. In pleading guilty, Driouich has recognised the seriousness of his behaviour and the implications of his actions.
Cleveland Police Assistant Chief Constable Lisa Orchard said: "I want to thank the highly-skilled officers working at Cleveland Police and Counter Terrorism Policing North East for bringing this man to justice. It is the responsibility of all of us to report any concerns or suspicions that we have so we can prevent and detect terrorist activity and ultimately save lives."