Crews used 10 breathing apparatus, two hose reels, two jets, two compressed air foam jets and the aerial ladder platform to bring the fire at Winton School in Andover under control.
Group Manager Dan Tasker said: "The first crews to arrive were met with a challenging situation of a confirmed fire plus the evacuation of 500 pupils."
More top news
Sunny spells continuing to develop into this evening. Dry with mostly clear skies overnight, before a sunny but chilly start tomorrow
Dry with sunny spells into this evening. Turning chilly with clear spells overnight with a sunny but cold start tomorrow
Dry with an increasing amount of bright spells this afternoon but feeling cool