Galectins are important for recognition of carbohydrate ligands during embryogenesis, development and immune regulation. In addition, recent work has shown that galectins also function as receptors for glycans expressed on the surface of potentially pathogenic microorganisms. In this Review, Gerardo Vasta discusses the roles of galectins in host immunity and how pathogens have evolved to evade or subvert galectin-mediated immune responses.