The objective was to measure teat canal length and diameter, teat diameter and teat wall thickness by ultrasonographic scanning in order to determine the differences in bovine breeds, and to study the influence of teat canal length and diameter on the occurrence of mastitis. A total of 269 lactating dairy cows of four different breeds (Brown Swiss, Simmental, Simmental crossbred with Red Pied, and Holstein-Friesians) from seven Upper Austrian dairy farms were examined. Average teat canal length of Brown Swiss animals was shortest (15·7 mm) followed by Holstein-Friesians (17·2 mm) and Simmental (18·3 mm). These differences in teat canal length were highly significant (P[les ]0·001). There was no significant difference in teat canal length between pure-bred and crossbred Simmentals. Differences of teat canal diameter between breeds were significant (P[les ]0·05). Brown Swiss animals had the largest diameters (2·0 mm) and Holstein-Friesians the smallest (1·7 mm). Differences in teat diameter between Brown Swiss, Holstein-Friesian and Simmental were also significant. No differences were found between the pure-bred and crossbred Simmental cows. The narrowest teats were in Holstein-Friesians and the widest in Simmental. Holstein-Friesians also exhibited the thinnest teat walls while the Simmental had the thickest ones. Teat canal length and diameter were correlated with udder health. Teat canals of healthy udders tended to be longer (17·4 mm) and narrower (1·8 mm) than teat canals of infected udders (15·8 mm, 2·1 mm; P[les ]0·001). A logistic regression model showed significant effects of teat canal length, teat canal diameter and lactation number on udder health.