The 15-year-old, who cannot be named for legal reasons and was 14 at the time of the offence, was found guilty by a jury at Winchester Crown Court of luring her friend to a quiet corner of the grounds of their Hampshire school on April 25 with the promise of giving her a present.
But the trial heard that after she asked her friend to close her eyes, the defendant pulled out the knife from her bag and lunged at her.
Her victim opened her eyes at the moment she was being stabbed and pulled away, escaping with a minor injury.
The defendant described herself as “motivated” by mass killers such as the Columbine duo and produced a journal with a plan for a school shooting which included a “kill list” of 60 people, but later burnt the book.
The judge, Mr Justice Fraser, said the girl’s oral evidence at trial had been “quite chilling” and handed her an extended sentence of 14 years.
This comprised a 10-year custodial term and an extended licence period of four years.
He said: “There was no animosity or hostility on your part towards (the victim) - she was just a convenient target.”
Mr Justice Fraser said the defendant was also “simply mistaken” in her belief held before the stabbing that her victim had been involved in online bullying she had suffered.
Before the sentence was handed down, Crown prosecutor James Newton-Price read excerpts from two statements written by the victim’s mother.
In them, the woman described the toll the crime had taken on her daughter and said the girl now asked questions such as: “How will I know in the future if someone is my friend or if they just want to stab me?”
The statement continued: “How will I know if they want to hurt me?”
The woman recalled finding her daughter looking at old photographs of her and her attacker and said she still expressed concern about her friend’s welfare.
The court heard the girl said: “She was my friend. She is my friend. I miss her, is she alright? Is she okay?”
The incident was the subject of “gossip and speculation” at school and the girl had suffered a “complete breakdown” at the conclusion of the trial, the statement said.
She was later diagnosed with post-traumatic stress disorder and twice needed counselling for anxiety-related issues during a family trip to Devon, it was heard.
“The trial was devastating for her and our family,” the court heard.
The mother urged her daughter’s attacker to think about the consequences of what she had done to “someone who held her in the deepest affection”.
Defence counsel Michael Parroy QC said his client could only be described as “a troubled young lady” and felt a “sense of dismay” about what had happened.
He said: “It is perhaps a considerable tragedy that (her) outer persona did not accurately reflect the inner turmoil.”
His client had been regarded as an intelligent and articulate person, capable of being a good person, but “carried inside her this particular devil”.
The court heard reports suggested she did not have a mental illness but rather a “personality problem” that manifested in ways including a lack of empathy.
The 234 days the girl, who pleaded guilty to a charge of possessing a knife on school premises, has already spent in custody will count towards her custodial term.