We investigated foraging decisions by adult females of the common green bottle fly, Lucilia sericata, in accordance with their physiological state. When we gave female flies a choice between visually occluded, fresh canine feces (feeding site) and a CO2-euthanized rat (carrion oviposition site), 3-d-old "protein-starved" females responded equally well to feces and carrion, whereas protein-fed gravid females with mature oocytes responded only to carrion, indicating resource preferences based on a fly's physiological state. Dimethyl trisulfide (DMTS) is known to attract gravid L. sericata females to carrion. Therefore, we analyzed headspace from canine feces by gas chromatographic-electroantennographic detection (GC-EAD) and GC/mass spectrometry. In bioassays, of the 17 fecal odorants that elicited GC-EAD responses from fly antennae, a blend of indole and one or more of the alcohols phenol, m-/p-cresol and 1-octen-3-ol proved as attractive to flies as canine feces. Unlike young females, gravid females need to locate carrion for oviposition and distinguish between fresh and aging carrion, the latter possibly detrimental to offspring. Gravid female L. sericata accomplish this task, in part, by responding to trace amounts of DMTS emanating from fresh carrion and by discriminating against carrion as soon it begins to produce appreciable amounts of indole, which is also the second-most abundant semiochemical in fresh canine feces, and apparently serves as an indicator of food rather than oviposition resources. Our results emphasize the importance of studying foraging choices by flies in accordance with their physiological stage.