Theory of mind (ToM) is the ability to interpret and understand human behaviour by representing the mental states of others. Like many human capacities, ToM is thought to develop through both complex biological and socialization mechanisms. However, no study has examined the joint effect of genetic and environmental influences on ToM. This study examined how variability in the oxytocin receptor gene (OXTR) and parenting behaviour—two widely studied factors in ToM development—interacted to predict ToM in pre-school-aged children. Participants were 301 children who were part of an ongoing longitudinal birth cohort study. ToM was assessed at age 4.5 using a previously validated scale. Parenting was assessed through observations of mothers’ cognitively sensitive behaviours. Using a family-based association design, it was suggestive that a particular variant (rs11131149) interacted with maternal cognitive sensitivity on children’s ToM (P = 0.019). More copies of the major allele were associated with higher ToM as a function of increasing cognitive sensitivity. A sizeable 26% of the variability in ToM was accounted for by this interaction. This study provides the first empirical evidence of gene–environment interactions on ToM, supporting the notion that genetic factors may be modulated by potent environmental influences early in development.