Disclosed is a method for controlling the milking by a milking machine. The machine comprises a plurality of teat cups (19), each teat cup having a flexible teat receiving liner arranged inside a rigid teat cup shell. During milking, a working vacuum is applied to the interior of the teat receiving liner of each teat cup to draw milk from a respective teat of a milking animal while the teat receiving liner of the respective teat cup is periodically opened and collapsed by application of a pulsating vacuum between the teat receiving liner and the teat cup shell. According to the method a flow level of milk drawn from the milking animal is measured and, if the measured flow level is above a threshold, the pulsation ratio of the periodic opening and collapsing of the teat receiving liner of one or more of the teat cups is decreased for a following part of the milking or for a following milking of the milking animal.