In physics, the conservation of energy is that energy can not be created or destroyed, it can only be changed from one form to another, such as when electrical energy is changed into heat energy. Formally, it says that the total amount of energy in an isolated system remains constant, although it may change forms, e.g. friction turns kinetic energy into thermal energy. In thermodynamics, the first law of thermodynamics is a statement of the conservation of energy for thermodynamic systems.
From a mathematical point of view, the energy conservation law is a consequence of the shift symmetry of time; energy conservation is a result of the empirical fact that the laws of physics do not change with time itself. Philosophically, this can be stated as "nothing depends on time per se (time itself)".