Organisms are often confronted by both predators and pathogens. Defending against such widely divergent enemies requires more than one type of defence. Multiple defences, however, raise the possibility of trade-offs among defences. We tested for such trade-offs by manipulating the level of predator-avoidance behaviour and immune function in the freshwater snail Lymnaea stagnalis (Gastropoda: Pulmonata). Our results show that predator avoidance and immune function had clear costs in terms of reproduction and survival. Further, we show that increased levels of predator-avoidance behaviour reduced the snails' ability to defend against potential pathogens. Predator-avoidance behaviour may thus have the additional indirect cost of reduced immunocompetence and increased susceptibility to pathogens. Our results suggest that ecological factors (e.g. predator density) may considerably modify the expression and costs of immune defences.