Lice of mammals spend the entire life cycle in the host hair, thus, the microclimate found near the mammal skin is likely to influence the structure of louse communities. Here we use a comparative approach to examine the effect of mammals' diving behavior on the taxonomic richness of their lice. We compared the mean genera richness of lice, and — as potential confounding variables — the mean species richness of host, and the mean body mass of host between diving clades and their non-diving sister clades. Louse genera richness was significantly lower in clades of aquatic mammals than on their non-diving sister clades. Host species richness was not significantly different between these clades. Body mass was significantly higher in clades of aquatic mammals, however, the direction of this difference cannot explain the difference in parasite taxonomic richness. This study suggests that mammals' diving behavior can effectively shape their ectoparasite communities.