Compared to non-flying nest-dwelling ectoparasites, the biology of most species of flying ectoparasites and its potential impact on avian hosts is poorly known and rarely, if ever, reported. In this study we explore for the first time the factors that may affect biting midge (Diptera: Ceratopogonidae) and black fly (Diptera: Simuliidae) abundances in the nest cavity of a bird, the hole-nesting blue tit Cyanistes caeruleus, and report their effects on adults and nestlings during reproduction. The abundance of biting midges was positively associated with nest mass, parental provisioning effort and abundance of blowflies and black flies, while negatively associated with nestling condition. Furthermore, a medication treatment to reduce blood parasitaemias in adult birds revealed that biting midges were more abundant in nests of females whose blood parasitaemias were experimentally reduced. This finding would be in accordance with these insect vectors attacking preferentially uninfected or less infected hosts to increase their own survival. The abundance of black flies in the population was lower than that of biting midges and increased in nests with later hatching dates. No significant effect of black fly abundance on adult or nestling condition was detected. Blood-sucking flying insects may impose specific, particular selection pressures on their hosts and more research is needed to better understand these host–parasite associations.