A machine (1) for manufacturing liquid or semi-liquid food products, comprising: - a frame (2); - a plurality of first containers (3) containing a basic liquid or semi-liquid mixture and comprising a deformable wall (4), whereby the space occupied by each first container (3) depends on an amount of basic mixture in it first container (3); - a second rigid container (5) forming a processing chamber for said basic mixture and provided with a mixer (6) with heat treatment means (7) for the basic mixture, which operate together to convert said basic mixture into a liquid or semi-liquid product; - connection means (8) to connect the first containers (3) to the second container (5), configured to allow the operative connection of one of said first containers (3) to the second container (5) and to transfer the basic mixture of one of said first containers (3) to the second container (5); - support means (9) for said first containers (3), operatively associated with said frame (2), said machine (1) being characterized by further comprising: - at least one sensor (10) configured to make available a signal representative of the amount of basic mixture in at least one of the first containers (3) that is operatively connected to the second container (5); - a control and drive unit (11) connected to said sensor (10) to receive said signal and configured to infer, based on said signal, a condition of no mixing in said one of the first containers (3) that is operatively connected to the second container (5), the machine being characterized in that the connection means (8) for connecting the first containers (3) to the second container (5) comprise at least one transfer pump (14) configured to allow a transfer of basic mixing from the first containers (3) to the second container (5), and are configured to allow the selective connection of the transfer pump (14) to, and the disconnection of said pump from, each of said first containers ( 3), said control unit (11) being connected to