How do glow sticks glow?

Inside a glow stick is a thin glass vial containing chemicals. When
you bend the stick you’re breaking this vial open, releasing the
chemicals into the rest of the glow stick, where other chemicals
react with them and release light.
Some chemical reactions produce light, known as
‘chemiluminescence’. Usually the vial contains a solution phenyl
oxalate ester and a fluorescent dye – which will determine the colour
of the glow stick – while the surrounding tube contains a solution of
hydrogen peroxide. Mixing these compounds causes the electrons to
rise to a higher energy level and return to their normal state, releasing
energy as light as they do.