The youth, who can not be named, was just 16 when he carried out the unprovoked attack on Harry Andrews, 19, at a house in Bradley Close, Louth.
Mr Andrews, who was visiting a female friend with two other pals, needed eight stitches to a head wound, Lincoln Crown Court heard.
Passing sentence Judge Michael Heath told the youth, now 17, that he could have “easily killed” Mr Andrews during the attack on May 28.
Judge Heath said: “You stabbed at him twice to the head, but you only made contact once.
He said: “You inflicted a wound to his head which required eight stitches.”
The judge also made a restraining order which prevents the teenager from having any contact with Mr Andrews.
Judge Heath added it was clear that the youth was “jealous” of Mr Andrews.
Andrew Scott, prosecuting, said there had been concerns about the youth’s “controlling nature”.
At around 3.10pm on May 28 he entered the house in Bradley Close through the kitchen.
The court heard he spontaneously picked up a large kitchen knife from a block and then went in to the lounge where Mr Andrews was watching television with his two friends.
The youth, who pleaded guilty to wounding Mr Andrews with intent to cause him grievous bodily harm, aimed two blows but only one struck.
Alison Summers, mitigating, said the teenager did not go to the house with the intention of using a knife.
Miss Summers added: “The decision to pick up the knife and the intention to use it was spontaneous.
“Although there were two strikes, only one made contact with Mr Andrews. Almost straight afterwards he dropped the knife.”
Mr Andrews was taken to hospital in Grimsby where his wound was stitched.
In a victim impact statement, Mr Andrews described how he had suffered nightmares and sickness after the attack.
He was subsequently diagnosed with post traumatic stress disorder and still suffers from anxiety and depression.
Mr Andrews attended court with his parents and said afterwards: “I am just glad that it is all over and justice has been done.
“I am now looking forward to the next month spending some quiet time with my family.”