Interspecific associations can arise for varied reasons including reduced predation risk and improved foraging success. In the case of bird–primate associations, birds typically appear to follow primate groups to harvest insects flushed by primates' movements. However, while previous studies have linked temporal changes in bird–primate associations to environmental conditions, few have assessed the additional effects of bird activity patterns and primate group behaviour and none have disentangled their potentially interdependent effects. Here, we test the hypothesis that foraging opportunities can drive interspecific associations in a previously undescribed bird–primate association between rock kestrels Falco rupicolus and chacma baboons Papio ursinus in central Namibia. Data were collected from two baboon groups and associated kestrels using instantaneous scan sampling during full-day follows over a 7-month field period, and analysed using generalized linear mixed models. We found that kestrel associations with baboons vary with season, show diurnal cycles and are more frequent when the baboons are in open desert habitat, engaged in travel foraging and in a large group. These patterns are statistically independent and consistent with the hypothesis that the kestrel–baboon association is driven by the foraging opportunities acquired by the kestrels. As the baboons do not appear to gain any benefits nor incur any costs from the association, we conclude that the kestrels are likely to be commensal with the baboons.