A hot water energy storage system comprising: a storage vessel; a pump arranged, in use, to pump water to and from the storage vessel; a heat exchanger having an inlet and an outlet and being arranged, in use, to receive water from the storage vessel at the inlet and to output water to the storage vessel via the outlet; a diverting valve arranged, in use, to divert a proportion of the water output from the heat exchanger back to the inlet of the heat exchanger, bypassing the storage vessel; one or more temperature sensors (120a, 120b, 120c) arranged, in use, to measure a temperature of water within the system; and a control system, the control system being arranged to control, based on at least one temperature measurement of the water within the system and the desired quantity of heat to be transferred to or from the water by the heat exchanger: (i) the pump, such that the flow rate of water is regulated; and (ii) the diverting valve, such that the proportion of water which is diverted is regulated, to maintain the return temperature of the water supplied to the storage vessel within a specified range whilst transferring the desired quantity of heat, and wherein: (i) if the system is arranged to be used for heating, and the specified range within which the control system is arranged to maintain the return temperature means the lowest temperature consistent with ensuring that the return temperature is equal to or higher than the maximum temperature to which the system is arranged to be heating a space, room, environment, water or other target to be heated; and (ii) if the system is arranged to be used for cooling, and the specified range within which the control system is arranged to maintain the return temperature means the highest temperature consistent with ensuring that the return temperature is equal to or lower than the minimum temperature to which the system is arranged to be cooling a space, room, environment, water or other target to be cooled. a storage vessel; a pump arranged, in use, to pump water to and from the storage vessel; a heat exchanger having an inlet and an outlet and being arranged, in use, to receive water from the storage vessel at the inlet and to output water to the storage vessel via the outlet; a diverting valve arranged, in use, to divert a proportion of the water output from the heat exchanger back to the inlet of the heat exchanger, bypassing the storage vessel; one or more temperature sensors (120a, 120b, 120c) arranged, in use, to measure a temperature of water within the system; and a control system, the control system being arranged to control, based on at least one temperature measurement of the water within the system and the desired quantity of heat to be transferred to or from the water by the heat exchanger: (i) the pump, such that the flow rate of water is regulated; and (ii) the diverting valve, such that the proportion of water which is diverted is regulated, (i) the pump, such that the flow rate of water is regulated; and (ii) the diverting valve, such that the proportion of water which is diverted is regulated, to maintain the return temperature of the water supplied to the storage vessel within a specified range whilst transferring the desired quantity of heat, and wherein: (i) if the system is arranged to be used for heating, and the specified range within which the control system is arranged to maintain the return temperature means the lowest temperature consistent with ensuring that the return temperature is equal to or higher than the maximum temperature to which the system is arranged to be heating a space, room, environment, water or other target to be heated; and (ii) if the system is arranged to be used for cooling, and the specified range within which the control system is arranged to maintain the return temperature means the highest temperature consistent with ensuring that the return temperature is equal to or lower than the minimum temperature to which the system is arranged to be cooling a space, room, environment, water or other target to be cooled. (i) if the system is arranged to be used for heating, and the specified range within which the control system is arranged to maintain the return temperature means the lowest temperature consistent with ensuring that the return temperature is equal to or higher than the maximum temperature to which the system is arranged to be heating a space, room, environment, water or other target to be heated; and (ii) if the system is arranged to be used for cooling, and the specified range within which the control system is arranged to maintain the return temperature means the highest temperature consistent with ensuring that the return temperature is equal to or lower than the minimum temperature to which the system is arranged to be cooling a space, room, environment, water or other target to be cooled.