A machine for making liquid or semi-liquid products, comprising: a first processing container (2) for processing a basic liquid or semi-liquid product and defining a processing chamber (3); - a cooling cylinder (20) mounted inside the first container (2); - a second processing container (21); - a connecting duct (52) between the first container (2) and the second container (21); - a dispensing device (23) associated with the first processing container (2) and configured, in a dispensing configuration, to deliver the liquid or semi-liquid product to the outside or, in an inhibiting configuration, to prevent the liquid or semi-liquid product from being dispensed; - a shutoff valve (26) configured, in a closed configuration, to close the connecting duct (52) between the first container (2) and the second container (21) or, in an open configuration, to open the connecting duct (52) between the first container (2) and the second container (21).