Caregivers’ nutrition knowledge and attitudes may influence the variety of foods available in the household and the quality of children’s diets. To test the link, this study collected data on caregivers’ (n 608) nutrition knowledge and feeding attitudes as well as the diets of their household and of their 2–5-year-old children in twelve rural communities nested in the three main agro-ecological zones of Ghana. Household foods and children’s animal source foods (ASF) consumed in the past 7 d were categorised into one of fourteen and ten groups, respectively. About 28 % of caregivers believed that their children needed to be fed only 2–3 times/d. Reasons for having adult supervision during child meal times, feeding diverse foods, prioritising a child to receive ASF and the perceived child benefits of ASF differed across zones (P<0·001). Households with caregivers belonging to the highest tertile of nutrition knowledge and attitude scores consumed more diverse diets compared with those of caregivers in the lowest tertile group (11·2 (sd 2·2) v. 10·0 (sd 2·4); P<0·001). After controlling for the effect of agro-ecological zone, caregivers’ nutrition knowledge and feeding attitudes positively predicted household dietary diversity and the frequency and diversity of children’s ASF intakes (P<0·001). The number of years of formal education of caregivers also positively predicted household dietary diversity and children’s ASF diversity (P<0·001). A key component to improving child nutrition is to understand the context-specific nutrition knowledge and feeding attitudes in order to identify relevant interventions.