Artificial intelligent assistant

Why insects are attracted towards light? Many insects like bees, dragonflies, wasps and other small insects are attracted towards light. Sometimes they are in groups, sometimes they are in solitude. When the light source source is switched off, they do not fly, rather stay still. What causes them to be so attracted towards light?

Phototaxis is a common behavior to many species, including insects but not only ( _e.g._ most fishes do phototaxis).

The ethological reason is quite simple: with light you can see, and if you see you can find food, avoid predators and increase your survival chances. Phototaxis is thus a very strong innate reflex: at the neural scale in many species it is "hardwired".

I would say that the initial "purpose" of this reflex was to avoid shade areas during daytime, the light during nightime being pretty rare before man invented artificial light. The fact that insects gather around artificial lights during nightime is, to me, a side effect of this reflex.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 288b7b5c93440000fd266f5874dfab6e