Heat, the energy we use in cooking, is the most universal form of energy.
All other energy forms, chemical energy, energy of motion (kinetic energy), electrical energy, nuclear energy, eventually degenerate into heat, which you might say is a sort of energy of last resort.
As chemical reactions give off energy, as moving things slow down, as a lamp converts electrical energy into light, as uranium atoms convert mass into radioactivity and heat, there can never be a 100 percent conversion. Inefficiency seems to be built into the universe.
Some of the lost or converted energy must inevitably be “wasted” by being turned into heat. You might think of heat as a tax on the conversion of energy; it’s like the fee charged by a money exchanger for converting one form of currency into another.
Most forms of energy can be well-behaved. For example, kinetic energy is well-behaved when a truck is moving in a straight line down a highway. Electrical energy is well-behaved when the movement of electrons is being controlled by a circuit. Nuclear energy comes from the very carefully controlled splitting of atoms.
In contrast to all this, however, heat is a shockingly ill-behaved and disorderly form of energy, because it consists of the wild, random movement of atoms and molecules.
The science of thermodynamics has found that whenever a form of energy, such as the chemical energy in a truck’s diesel fuel or in the uranium of a nuclear reactor, is being converted into another form, the disorderliness or randomness (the entropy) of the system must increase. That’s the Second Law of Thermodynamics. The universe is inexorably winding down by losing energy and creating disorder. Chaos.
So whenever a form of energy is being used up or converted into another, some of a disorderly, more chaotic, higher entropy form of energy must be produced. That’s heat.
For further details, consult your friendly neighborhood thermodynamicist.