The main ingredients in highlighter ink are water and glycol solvent. Around 5 percent of the ink is fluorescent pigment or dye. Some highlighters also contain a small amount of biocide to prevent the growth of fungus and bacteria.
The dyes used in yellow highlighting pens are pyrene-based. Blue highlighters contain triphenylmethane dye. Triphenylmethane dye combined with pyranine produces green highlighting ink. Pink highlighters contain rhodamine. Purple highlighters are made with rhodamine mixed with triphenylmethane. Xanthene combined with coumarin produces purple highlighter ink.
The chemical molecules in highlighter ink absorb ultraviolet light. This “excites” the electrons inside the molecules, which then release a slightly longer waveform of the light. This interaction of light and chemicals is interpreted by the eye as fluorescence.