Insect olfaction refers to the function of chemical receptors that enable insects to detect and identify volatile compounds for foraging, predator avoidance, finding mating partners (via pheromones) and locating oviposition habitats. Thus, it is the most important sensation for insects. Most important insect behaviors must be timed perfectly which is dependent on what they smell and when they smell it. For example, olfaction is essential for locating host plants and hunting prey in many species of insects, such as the moth Deilephila elpenor and the wasp Polybia sericea, respectively.
The two organs insects primarily use for detecting odors are the antennae and specialized mouth parts called the maxillary palps. However, a recent study has demonstrated the olfactory role of ovipositor in fig wasps. Inside of these olfactory organs there are neurons called olfactory receptor neurons which, as the name implies, house receptors for scent molecules in their cell membrane. The majority of olfactory receptor neurons typically reside in the antenna. These neurons can be very abundant; for example, Drosophila flies have 2,600 olfactory sensory neurons.