Most people think that insects fly to bug zappers because they’re stupid, or crave it. Actually it messes with their navigation. Normally insects utilize the sun or moon as a stable reference point. Because those bodies of light are so far away, a little movement does not seem to affect its position relative to the observer. Artificial light sources however, are close enough to move a tiny bit as the insect moves. The hapless invertebrate assumes it has made a navigation error and ends up spiraling in towards the light.