All metazoan guts are in constant contact with diverse food-borne microorganisms. The signaling mechanisms by which the host regulates gut-microbe interactions, however, are not yet clear. Here, we show that phospholipase C-beta (PLCbeta) signaling modulates dual oxidase (DUOX) activity to produce microbicidal reactive oxygen species (ROS) essential for normal host survival. Gut-microbe contact rapidly activates PLCbeta through Galphaq, which in turn mobilizes intracellular Ca(2+) through inositol 1,4,5-trisphosphate generation for DUOX-dependent ROS production. PLCbeta mutant flies had a short life span due to the uncontrolled propagation of an essential nutritional microbe, Saccharomyces cerevisiae, in the gut. Gut-specific reintroduction of the PLCbeta restored efficient DUOX-dependent microbe-eliminating capacity and normal host survival. These results demonstrate that the Galphaq-PLCbeta-Ca(2+)-DUOX-ROS signaling pathway acts as a bona fide first line of defense that enables gut epithelia to dynamically control yeast during the Drosophila life cycle.