A method for controlling a temperature of a fluid carrier medium flowing through an energy generator, wherein the energy generator heats or cools the carrier medium before it flows via an feed line to a load and then via a return line back to the energy generator, comprising the steps of: acquiring a control deviation ( e) between a setpoint value (θ w) and an actual value (θ x) of the temperature; determining a first control variable for setting a power of the energy generator, controlling the temperature of the fluid carrier medium using the first control variable so as to minimize the control deviation ( e) between the setpoint value (θ w) and the actual value ( θ x) of the temperature; defining a minimum settable power ( Q̇ min) of the energy generator; defining a maximum settable power ( Q̇ max) of the energy generator; determining a second control variable for setting a mass flow ( ṁ) of the fluid carrier medium through the energy generator depending on the minimum settable power ( Q̇ min) and the maximum settable power ( Q̇ max). the temperature being controlled using the first and second control variables, characterized by the steps: if the actual value (θ x) is less than the setpoint value (θ w) and the energy generator heats the carrier medium or the actual value ( θ x) is greater than the setpoint value (θ w) and the energy generator cools the carrier medium: either determining and outputting the first control variable for setting the power of the energy generator in order to increase the power when the power is less than the maximum settable power ( Q̇ max); or determining and outputting the second control variable for setting the mass flow ( ṁ) of the carrier medium through the energy generator in order to reduce the mass flow ( ṁ) when the power of the energy generator is equal to the maximum settable power ( Q̇ max). acquiring a control deviation ( e) between a setpoint value (θ w) and an actual value (θ x) of the temperature; determining a first control variable for setting a power of the energy generator, controlling the temperature of the fluid carrier medium using the first control variable so as to minimize the control deviation ( e) between the setpoint value (θ w) and the actual value ( θ x) of the temperature; defining a minimum settable power ( Q̇ min) of the energy generator; defining a maximum settable power ( Q̇ max) of the energy generator; determining a second control variable for setting a mass flow ( ṁ) of the fluid carrier medium through the energy generator depending on the minimum settable power ( Q̇ min) and the maximum settable power ( Q̇ max). the temperature being controlled using the first and second control variables, characterized by the steps: if the actual value (θ x) is less than the setpoint value (θ w) and the energy generator heats the carrier medium or the actual value ( θ x) is greater than the setpoint value (θ w) and the energy generator cools the carrier medium: either determining and outputting the first control variable for setting the power of the energy generator in order to increase the power when the power is less than the maximum settable power ( Q̇ max); or determining and outputting the second control variable for setting the mass flow ( ṁ) of the carrier medium through the energy generator in order to reduce the mass flow ( ṁ) when the power of the energy generator is equal to the maximum settable power ( Q̇ max). either determining and outputting the first control variable for setting the power of the energy generator in order to increase the power when the power is less than the maximum settable power ( Q̇ max); or determining and outputting the second control variable for setting the mass flow ( ṁ) of the carrier medium through the energy generator in order to reduce the mass flow ( ṁ) when the power of the energy generator is equal to the maximum settable power ( Q̇ max).