The Durham County Sheriff's Office said school resource officers were made aware of a video the student made of himself holding the weapon while at the school.
The student, a juvenile, was identified and searched. Authorities found a stolen handgun on him and an extended magazine loaded with hollow-point ammunition.
"We are grateful to the individual who brought this to our attention," said Sheriff Clarence Birkhead. "We encourage the entire Durham Public Schools community to remain vigilant regarding potential violence on our campuses. If you see something, say something by telling a trusted adult, our SROs, or by utilizing the tip line."
The 16-year-old student was charged with possession of a weapon on educational property, possession of a stolen firearm, carrying a concealed weapon, resist delay and obstruct arrest, and possession of a weapon by a minor
The teen was being held in secure custody Wednesday evening, the sheriff's office said.
ALSO SEE | Durham County Sheriff, Durham Police Chief address gun violence during community meeting
Durham Sheriff, Police Chief address gun violence
ABC11 is tracking crime and safety across Durham and in your neighborhood