A longitudinal study in England and Wales of two dairy, five beef-fattener and three beef-suckler herds was carried out to identify risk factors for young cattle excreting verocytotoxin-producing Escherichia coli O157 (VTEC O157). A total of 1383 cattle, selected into cohorts at 0–24 months were sampled between March 2000 and February 2001. Mixed-effects logistic regression was employed to identify significant associations between VTEC O157 isolation from rectal faecal samples and explanatory factors (P < 0·001 unless shown). The results revealed a positive association with feeding root crops and a negative association with animals fed silage, milk (P = 0·001) or grain (P = 0·027). Cattle in suckler herds (P = 0·001) and those changing group between sampling visits were identified as negatively associated with VTEC O157 presence. The recovery of VTEC O157 varied throughout the year. However, the winter period from December to February was a risk factor in the multivariable analysis. Cattle in pens were 4·7 times more likely to shed VTEC O157 than those group-housed or at pasture. VTEC O157 detected in pooled environmental faecal pats and biofilm of the water supply within a group's enclosure were positively associated with an animal's VTEC O157 status in the multivariable logistic regression, as was detection of VTEC O157 in the pooled faecal pats at the previous visit.