It took about a half-hour to get a fire under control at McLane Middle School.
Hillsborough County Fire Rescue firefighters were called around 11 p.m. Friday to the school on Knights Avenue and found flames shooting through the building's roof, the agency said.
Firefighters attacked the flames at the two-story building from the ground and air. About 30 minutes later, the fire was under control.
No one was hurt.
The school district suspects a lightning strike caused the fire on the roof of building 600, which contains eight classrooms. It's believed the building is a total loss.
Vanessa Perez was visiting a friend's house in the area when she saw "a bunch" of police cars outside.
"We went outside and it felt like a lot of hot air," she said. "The fire going all the way up to the sky, it was really big ... it just wouldn't go out."
When school starts next month, students likely will be moved to other parts of the school's campus, the district added.