Immunity represents an important defense mechanism against pathogens and is intimately linked to fitness. Previous studies have found significant interindividual variation of immune responses in wild populations and have emphasized the importance of ecological factors in explaining this variability. A deterioration of environmental conditions, such as agricultural intensification, can modify resource availability and, as a result, alter immune functions. The aim of this study was to investigate the effect of agricultural intensification on innate immune functions in breeding adult tree swallows (Tachycineta bicolor) over 6 yr. We investigated the relationship between agricultural intensification and bacteria-killing ability (BKA) against a strain of E. coli. We also assessed how the presence and the number of bacteria on the surface of eggshells changed with agricultural intensification. Contrary to our expectations, we found a positive relationship between agricultural intensification and BKA, where individuals had higher BKA in intensive compared to nonintensive farmlands. While this trend was observed through the 6-yr study, we also found a tendency for a reduction of BKA over time. We found no relationships between the presence or number of different types of eggshell bacteria and agricultural intensification or an association between BKA of females and eggshell bacteria of their clutch. Our results suggest that differences in immune function observed between intensive and nonintensive farmlands could reflect genetic differences among individuals and/or trade-offs with other traits expressed among habitats within our study system.