The discovery of the key role of Toll-like receptors (TLRs) in initiating innate immune responses and modulating adaptive immunity has revolutionized our understanding of vertebrate defence against pathogens. Yet, despite their central role in pathogen recognition and defence initiation, there is little information on how variation in TLRs influences disease susceptibility in natural populations. Here, we assessed the extent of naturally occurring polymorphisms at TLR2 in wild bank voles (Myodes glareolus) and tested for associations between TLR2 variants and infection with Borrelia afzelii, a common tick-transmitted pathogen in rodents and one of the causative agents of human Lyme disease. Bank voles in our population had 15 different TLR2 haplotypes (10 different haplotypes at the amino acid level), which grouped in three well-separated clusters. In a large-scale capture-mark-recapture study, we show that voles carrying TLR2 haplotypes of one particular cluster (TLR2c2) were almost three times less likely to be Borrelia infected than animals carrying other haplotypes. Moreover, neutrality tests suggested that TLR2 has been under positive selection. This is, to our knowledge, the first demonstration of an association between TLR polymorphism and parasitism in wildlife, and a striking example that genetic variation at innate immune receptors can have a large impact on host resistance.