Christopher Lambeth, 23, formerly of Ayrton Avenue, Marton, admitted robbing the three boys, Preston Crown Court. He stole two mobile phones, £10 and cigarettes during the incident.
Jon Close, prosecuting, described how Lambeth had initially approached the boys to “shout at them” for playing loud music.
But the confrontation ended with him threatening to stab them with a knife.
The court heard Lambeth, a qualified plumber, had suffered mental health issues.
Recorder Andrew Long said: “The sentence must be one of immediate custody both to punish this defendant and to deter others.
“I don’t know what possessed you to go from telling people off for playing loud music to robbing them – however that’s what you did, threatening to stab them.
“You haven’t got a good character, you have two assaults and harassment on your record, but I do accept this was wildly out of character and obviously committed at a low point in your life. I’m impressed by the good work you’ve been doing in prison.”
Lambeth’s defence lawyer had urged the court to consider a suspended sentence.
He added: “Mr Lambeth is a young man who has always worked since leaving school.
“He achieved seven GCSEs and did an NVQ at sixth form in plumbing. He then did a three year apprenticeship but at the end decided to take another career path, a decision he regrets.
“He spent time doing labouring, painting and decorating and working in a care home and then in April 2015 he found a job working for a large company in a customer service role many miles from his family home.
“It was really when he was away he encountered emotional and psychological difficulties to the point he became stressed and his GP signed him off from work a few months before this offence.
“He also suffered bereavements when two grandparents and a great grandparent died last year and it got to the point where he was considering suicide.”
He added: “He is shocked and disgusted at his actions on the day in question and it was out of character.”
Lambeth, who has since moved away from Blackpool, will be out by Christmas due to the time he has served on remand. The incident took place on March 13.