The 17-year-old suspect opened fire at Tocqueville high school, in Grasse, at about 12:40 local time (11:40 GMT).
More people were injured in the ensuing panic.
Anti-terrorist commandos from the elite Raid force were sent to the scene.
The suspect, who was reportedly armed with a rifle, two handguns and two hand grenades, was arrested "very quickly" after launching the attack.
Education Minister Najat Vallaud-Belkacem told reporters on Thursday afternoon the suspect was "fragile".
"It was a crazy act by a youth who is unstable and fascinated by guns," she said, going on to praise the headmaster's actions during the attack as "heroic".
According to Ms Vallaud-Belkacem, the headteacher tried to reason with the gunman, seemingly stopping the rampage in its tracks.
"We missed out on the worst," she said.
A student had earlier told local newspaper Nice Matin how the headteacher, named by the newspaper as Herve Pizzinat, had remained "cool", continuing to try to calm the suspect down even after he had been shot in the arm.
"He kept trying to bring him back to reason," the student said.
One student reported hearing four gunshots, while others described the panic in the moments after the attack began. Ten students were treated for shock or minor injuries caused as they tried to flee the shooter, according to the education secretary.
No-one was critically hurt. The headteacher had gunshot wounds, while the students were being treated for buckshot wounds.
Initial conflicting reports suggested there may have been a second shooter, but it appears this is not the case, although earlier on Thursday interior ministry spokesman Pierre-Henry Brandet said they had not ruled it out entirely and were still "searching for a possible second perpetrator".
The local prosecutor has confirmed the shooting had "no link" to terrorism. Instead, it is thought the student had bad relations with his classmates.
However, President Francois Hollande said France should remain "vigilant" and stay under a state of emergency.
Grasse, the capital of France's perfume industry, is about 44km (27 miles) from the city of Nice, where a lorry attack in July killed 86 people.
France remains under a state of emergency after a string of deadly attacks in the past 18 months.
A school shooting, which left three students and a headteacher wounded, appears to have been a "crazy act" carried out by a teenager obsessed with firearms, France's education minister has said.