Espen Andersen Brathen, who is Danish but lives in Norway, used a bow and arrow inside and outside a supermarket to attack several people before stabbing five other residents to death in their homes or on the street last October.
Last month, the 38-year-old who has long-suffered from mental illness, pleaded guilty to the charges of murder and attempted murder.
In their verdict delivered Thursday, the judges said “the defendant clearly had comprehension and functional disorders because of his condition” at the time of the attack.
“The court therefore finds that the defendant cannot be held criminally responsible for any of the charges,” the verdict said
Brathen had been living for years in Kongsberg, home to about 25,000 people some 80 kilometres (50 miles) west of the capital Oslo, and authorities have said he had a medical history.
The Norwegian security services PST, which are responsible for counter-terrorism, also said the man had been on their radar.
He was arrested 35 minutes after the first reports of an attack and was swiftly moved to a medical institution.
Three experts who observed him concluded that he was suffering from paranoid schizophrenia.
Both the prosecution and the defence argued that he could not be held criminally responsible and advocated a psychiatric commitment rather than a prison sentence.
According to the prosecution, Brathen was armed with a bow, 60 arrows and four knives on the day of the attacks.His victims were four women and one man aged from 52 to 78.