Palm Beach County Sheriff's spokeswoman Teri Barbera said the 6-year-old child's teacher at Somerset Academy Lakes Elementary School immediately picked up the gun after it fell Thursday morning and escorted the children out of the classroom. She said no students were endangered at the West Palm Beach School.
Principal Clint Duvo said in a statement the child didn't know how the gun got into the backpack and had no intention of bringing it to school.
Sheriff's detectives are investigating.
The school opened in 2016. Somerset Academy is a large charter school company with sites throughout Florida.
Copyright 2018 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.