Laboratory somatic cell count (LSCC) records are usually recorded monthly and provide an important information source for breeding and herd management. Daily milk viscosity detection in composite milking (expressed as drain time) with an automated on-line California Mastitis Test (CMT) could serve immediately as an early predictor of udder diseases and might be used as a selection criterion to improve udder health. The aim of the present study was to clarify the relationship between the well-established LSCS and the new trait,‘drain time’, and to estimate their correlations to important production traits. Data were recorded on the dairy research farm Karkendamm in Germany. Viscosity sensors were installed on every fourth milking stall in the rotary parlour to measure daily drain time records. Weekly LSCC and milk composition data were available. Two data sets were created containing records of 187 692 milkings from 320 cows (D1) and 25 887 drain time records from 311 cows (D2). Different fixed effect models, describing the log-transformed drain time (logDT), were fitted to achieve applicable models for further analysis. Lactation curves were modelled with standard parametric functions (Ali and Schaeffer, Legendre polynomials of second and third degree) of days in milk (DIM). Random regression models were further applied to estimate the correlations between cow effects between logDT and LSCS with further important production traits. LogDT and LSCS were strongest correlated in mid-lactation (r = 0·78). Correlations between logDT and production traits were low to medium. Highest correlations were reached in late lactation between logDT and milk yield (r = −0·31), between logDT and protein content (r = 0·30) and in early as well as in late lactation between logDT and lactose content (r = −0·28). The results of the present study show that the drain time could be used as a new trait for daily mastitis control.