Pictures taken by students and circulating in the media showed the assailant wearing black clothes and a Darth Vader-like mask, with school children initially thinking it was a prank or a Halloween costume.
Media reports identified the attacker as Anton Lundin Pettersson, describing him as a quiet 21-year-old opposed to Islam and immigration.
"He was a loner. He played video games, lived in his own world," a former classmate told daily Expressen.
The attack shocked a nation where such violence is rare.
One teacher was found dead at the school -- described in the media as a "problem school" -- while a young male student and the assailant both died in hospital several hours later.
"The assailant knocked on two classroom doors and he attacked the two students who opened the doors," police investigator Thord Haraldsson said.
Hospital staff had previously confirmed that two boys, aged 11 and 15, were in critical condition with stab wounds, while another teacher who was seriously wounded in the attack also underwent surgery.
Police have not disclosed his identity nor given any further information about him or the possible motive for the attack.
He did not have a criminal record and was not known to police, said law enforcement officials as police searched his home for clues.
However, Swedish news agency TT and daily Expressen reported that he had a YouTube account where he posted material glorifying Hitler and Nazi Germany and critical of Islam and immigration to Sweden.
The anti-racism magazine Expo meanwhile reported that its police sources said they were investigating a "political motive".
Police were alerted to the attack at 10:10 am (1310 IST).
You’ve reached your limit of {{free_limit}} free articles this month.
Subscribe now for unlimited access.
Already subscribed? Log in
Subscribe to read the full story →
Smart Quarterly
₹900
3 Months
₹300/Month
Smart Essential
₹2,700
1 Year
₹225/Month
Super Saver
₹3,900
2 Years
₹162/Month
Renews automatically, cancel anytime
Here’s what’s included in our digital subscription plans
Exclusive premium stories online
Over 30 premium stories daily, handpicked by our editors


Complimentary Access to The New York Times
News, Games, Cooking, Audio, Wirecutter & The Athletic
Business Standard Epaper
Digital replica of our daily newspaper — with options to read, save, and share


Curated Newsletters
Insights on markets, finance, politics, tech, and more delivered to your inbox
Market Analysis & Investment Insights
In-depth market analysis & insights with access to The Smart Investor


Archives
Repository of articles and publications dating back to 1997
Ad-free Reading
Uninterrupted reading experience with no advertisements


Seamless Access Across All Devices
Access Business Standard across devices — mobile, tablet, or PC, via web or app
