The release of energy in chemical reactions occurs when the reactants have higher chemical energy than the products. The chemical energy in a substance is a type of potential energy stored within the substance. This stored chemical potential energy is the heat content or enthalpy of the substance.
The collection of substances that is involved in a chemical reaction is referred to as a system and anything else around it is called the surroundings.
If the enthalpy decreases during a chemical reaction, a corresponding amount of energy must be released to the surroundings. Conversely, if the enthalpy increases during a reaction, a corresponding amount of energy must be absorbed from the surroundings. This is simply the Law of Conservation of Energy.
Endothermic reactions increase their enthalpy by absorbing heat. They feel cold to the touch after they have occurred. Exothermic reactions decrease their enthalpy by releasing heat. They will get warm, and may even burn or explode if they release enough heat.
You are already familiar with enthalpy: melting ice is exothermic and freezing water is endothermic.
Examples
When methane burns in air the heat given off equals the decrease in enthalpy that occurs as the reactants are converted to products.
The enthalpy difference between the reactants and the products is equal to the amount of energy released to the surroundings. A reaction in which energy is released to the surroundings is called an exothermic reaction. In this type of reaction the enthalpy, or stored chemical energy, is lower for the products than the reactants. When ammonium nitrate is dissolved in water, energy is absorbed and the water cools. This concept is used in "cold packs".
The enthalpy difference between the reactants and the products is equal to the amount of energy absorbed from the surroundings. A reaction in which energy is absorbed from the surroundings is called an endothermic reaction.