Method, implemented by computer-based means, for controlling and regulating a system for heating premises, over a period of time, based on a received, desired temperature setpoint defining a setpoint temperature (T cons), the method including the steps of: - developing a model for forecasting a total energy consumption of the premises, allowing an indoor temperature (Tint) inside the premises to be maintained which is equal to the setpoint temperature (T cons) over said period of time, said model being expressed as a function of the setpoint temperature (T cons) by an equation: C total = GV ∗ Pot degH − Threshold + Baseload where: -- C total represents the total energy consumption forecast for the premises over the period of time, -- GV represents a heat loss coefficient of the premises, -- Pot degH represents a positive deviation between an estimated indoor temperature (Tint) of the premises, and an outdoor temperature (T ext), said estimated indoor temperature (Tint) being dependent on the setpoint temperature (T cons), and said positive deviation being calculated at each time step over the period of time, -- Threshold represents an indoor temperature threshold (Tint) above which a system for heating the premises is placed in a deactivated state, and -- Baseload represents a total energy consumption for non-heat-sensitive uses of the premises, obtained from statistical data; - then defining a maximum value of the total energy consumption over the period of time, characterised in that the method comprises the step of: based on the model for forecasting the total energy consumption of the premises: --- obtaining, as an output, a new setpoint temperature (T cons ') to be reached in the premises such that the value of the total energy consumption of the premises is less than or equal to said maximum value at the end of the period of time, - the method comprising a further step of sending the new setpoint temperature (T cons ') to a thermostat allowing the heating system to be controlled and regulated, furthermore the model for forecasting the energy consumption is drawn up by iteratively calculating the indoor temperature (Tint) of the premises from thermal parameters (K 1, K2) of the premises, the outdoor temperature (T ext) and the indoor temperature (Tint) calculated during the previous iteration. - developing a model for forecasting a total energy consumption of the premises, allowing an indoor temperature (Tint) inside the premises to be maintained which is equal to the setpoint temperature (T cons) over said period of time, said model being expressed as a function of the setpoint temperature (T cons) by an equation: C total = GV ∗ Pot degH − Threshold + Baseload where: -- C total represents the total energy consumption forecast for the premises over the period of time, -- GV represents a heat loss coefficient of the premises, -- Pot degH represents a positive deviation between an estimated indoor temperature (Tint) of the premises, and an outdoor temperature (T ext), said estimated indoor temperature (Tint) being dependent on the setpoint temperature (T cons), and said positive deviation being calculated at each time step over the period of time, -- Threshold represents an indoor temperature threshold (Tint) above which a system for heating the premises is placed in a deactivated state, and -- Baseload represents a total energy consumption for non-heat-sensitive uses of the premises, obtained from statistical data; -- C total represents the total energy consumption forecast for the premises over the period of time, -- GV represents a heat loss coefficient of the premises, -- Pot degH represents a positive deviation between an estimated indoor temperature (Tint) of the premises, and an outdoor temperature (T ext), said estimated indoor temperature (Tint) being dependent on the setpoint temperature (T cons), and said positive deviation being calculated at each time step over the period of time, -- Threshold represents an indoor temperature threshold (Tint) above which a system for heating the premises is placed in a deactivated state, and -- Baseload represents a total energy consumption for non-heat-sensitive uses of the premises, obtained from statistical data; - then defining a maximum value of the total energy consumption over the period of time, characterised in that the method comprises the step of: based on the model for forecasting the total energy consumption of the premises: --- obtaining, as an output, a new setpoint temperature (T cons ') to be reached in the premises such that the value of the total energy consumption of the premises is less than or equal to said maximum value at the end of the period of time, - the method comprising a further step of sending the new setpoint temperature (T cons ') to a thermostat allowing the heating system to be controlled and regulated, furthermore the model for forecasting the energy consumption is drawn up by iteratively calculating the indoor temperature (Tint) of the premises from thermal parameters (K 1, K2) of the premises, the outdoor temperature (T ext) and the indoor temperature (Tint) calculated during the previous iteration.