The energy change that occurs as the result of a reaction depends on the difference between the energy of the reactants and the energy of the products.
For reactions like combustion, the fuel (for example wood) has energy stored in the chemical bonds between the atoms that make it up. When the wood burns and forms carbon dioxide and water, it releases some energy in the form of heat and light, while some remains stored in the bonds of carbon dioxide and water.
For some reactions, the products end up with more energy than the reactants (like when we might roll a car uphill). The energy change is still just a measure of the difference between the enrgy of the products, and the energy of the reactants.