A statement from the Shelby County school district said the gun went off inside a kindergarten student's backpack as students were waiting for the opening bell in the cafeteria of Westside Elementary School. There were no injuries. School staffers immediately took control of the backpack.
School security officers and the Memphis Police Department responded quickly, the district said. The child was detained and was still being questioned by officers Thursday afternoon, with the child's mother present. Police spokeswoman Karen Rudolph said investigators were trying to determine how the gun ended up in the backpack.
Students were kept safe and calm while the matter was handled, the district said.
There was no evidence of harmful intent, the school district said.
"However, weapons of any kind are prohibited on campuses, and this student will be disciplined in accordance with the state's zero tolerance policy," the statement said.
The zero-tolerance policy calls for "certain, swift and reasoned punishment" for students who bring drugs or guns to school. It could include expulsion.