Wikipedia
Bis-[2,4,5-trichloro-6-(pentyloxycarbonyl)phenyl]oxalate (also known as bis(2,4,5-trichloro-6-carbopentoxyphenyl) oxalate or CPPO) is a solid ester whose oxidation products are responsible for the chemiluminescence in a glowstick. It can be synthesized by reacting 2-carbopentoxy-3,5,6-trichlorophenol with oxalyl chloride. (Note: This article originally was called Bis(2,4,5-trichlorophenyl-6-carbopentoxyphenyl)oxalate, but the subsequently added picture and formula have only two phenyl groups. Since no references are given, it is unclear what compound is actually used in glowsticks.)
When mixed with hydrogen peroxide in an organic solvent (diethyl phthalate, ethyl acetate, etc...) in the presence of a fluorescent dye CPPO causes the emission of light, as per the following scheme involving 1,2-dioxetanedione (note that many side-groups of the aromatic rings are not shown.):
The reaction rate is pH dependent, and slightly alkaline conditions achieved by adding a weak base, e.g. sodium salicylate, will produce brighter light. Developed by American Cyanamid in the 1960s, the formulation containing CPPO, a fluorescor, and a glass capsule containing hydrogen peroxide and a base catalyst, all in dialkyl phthalate solvents, was marketed as Cyalume.
The following colors can be produced by using different dyes:
Color
Compound
Blue
9,10-Diphenylanthracene
Green
9,10-Bis(phenylethynyl)anthracene
Yellow-green
Tetracene
Yellow
1-Chloro-9,10-bis(phenylethynyl)anthracene
Orange
5,12-Bis(phenylethynyl)naphthacene, Rubrene, Rhodamine 6G
Red
2,4-Di-tert-butylphenyl 1,4,5,8-tetracarboxynaphthalene diamide, Rhodamine 101, Rhodamine B