Juvenile population size may affect the potential for future mating opportunities and therefore potentially sperm competition; this may favour ontogenetic adjustments in sperm production. Theory predicts that males should optimize their ejaculatory investment in accordance with the risk of sperm competition. Evidence for these theories is typically revealed in males of highly polyandrous species. Whether such responses to environmental cues exist for females, or are maintained in mildly polyandrous species in which most females do not re-mate, is unknown. Male lepidopterans produce normal, fertilizing sperm (eupyrene) and non-fertilizing (apyrene) sperm. Apyrene sperm are associated with reduced female receptivity, suggesting a role in sperm competition. We tested the effect of juvenile population size on life-history parameters and reproductive investment in the mildly polyandrous almond moth, Cadra cautella, a species in which current male ejaculate traits suggest previous selection for paternity protection consistent with a sperm-competitive environment. Larvae were reared at high (H) or low population sizes (L). We recorded larval development time, adult longevity and male gametic investment. Our results show a response by adults to signals in the juvenile environment. H males transferred more apyrene, but not eupyrene sperm. We also examined potential trade-offs between somatic characters and reproductive behaviours. Larval duration was longer for H individuals, females and heavier individuals. Further, H females and L males lived longer than L females. Our data are consistent with the theory that males should adjust their reproductive investment in accordance with sperm competition risk.