An investigation was conducted to determine the distribution, virulence gene profile and phenotypes of Shiga toxin-producing Escherichia coli (STEC) strains within a dairy farm in Kolkata, India by characterizing the STEC strains isolated from healthy dairy cow and calf stool samples, raw milk and farm floor swabs from July 2001 to March 2002. Primary screening by multiplex-PCR detected stx1 and stx2, the common virulence genes of STEC, in 18·9% of cow faeces, 32·4% of calf stool samples, 21·6% of farm floor swabs and 4·5% of raw milk samples and viable STEC were recovered from 4·5, 9·9, 8·1 and 1·8% of the corresponding PCR-positive samples. Strains harbouring stx1 (63·3%) and hlyA (53·3%) were frequently detected compared to eae (13·3%). Most of the strains harboured similar sets of reported virulence genes common among isolates from diarrhoea patients. Most of the strains also exhibited multidrug resistance, sorbitol fermentation and produced enterohaemolysin. The randomly amplified polymorphic DNA–PCR (RAPD–PCR) profile of the STEC strains isolated from the farm milieu revealed diverse banding patterns and clonal analysis demonstrated that the strains from different sources were not identical but showed some genetic relatedness. The study demonstrates the potential of dairy farm for housing virulent STEC.