Animal responses to their environment rely on activation of sensory neurons by external stimuli. In many sensory systems, however, neurons display basal activity prior to the external stimuli. This prior activity is thought to modulate neural functions, yet its impact on animal behavior remains elusive. Here, we reveal a potential role for prior activity in olfactory receptor neurons (ORNs) in shaping larval olfactory behavior. We show that prior activity in larval ORNs is mediated by the olfactory receptor complex (OR complex). Mutations of Orco, an odorant co-receptor required for OR complex function, cause reduced attractive behavior in response to optogenetic activation of ORNs. Calcium imaging reveals that Orco mutant ORNs fully respond to optogenetic stimulation but exhibit altered temporal patterns of neural responses. These findings together suggest a critical role for prior activity in information processing upon ORN activation in Drosophila larvae, which in turn contributes to olfactory behavior control.