The 14-year old said he wanted to kill teachers and students at Council Rock South last month.
Authorities found two handguns during a search of the boy's home.
He later pled guilty to making terroristic threats.
On Tuesday, a judge ordered the teen to remain in juvenile custody possibly until the age of 21.
His case will be reviewed very six months.
He must also write a letter of apology to the school.