Over the past two decades, the Gulf of California (GOC) has experienced three strong El Niño events ), each of which was followed by a drastic reduction in mantle length of mature Humboldt squid, Dosidicus gigas (from >60 cm to <20 cm). However, it is unclear how the oceanographic changes associated with strong El Niño events affected the midwater organisms on which D. gigas feed, limiting our ability to assess the relative importance of temperature and food availability in the phenotypic response of D. gigas to environmental variability. We quantified the diet of D. gigas in the GOC before, during, and following the past three El Niño events and found that although its diet varied little across a large range of body sizes (8-85 cm), significant and predictable diet variability was observed with respect to sea surface temperature and chlorophyll-a concentration. Consumption of large numbers of relatively small, high calorie prey in both relatively cool (anchovies) and relatively warm, productive conditions (myctophids) is likely necessary to support growth to large body sizes before maturation. When warm, unproductive conditions prevailed in the GOC, only small squid were present and had diets dominated by euphausiids and pteropods, prey with relatively low caloric value. Using a time series of diet data, this work provides unique insights into the response of a midwater forage community to oceanographic variability and the effects of environmental variability on the trophic ecology of an oceanic predator.