I am not sure if the previous answers are exactly correct.
The internal energy E of a system is the sum of the kinetic energies of all of the particles in a system and all of the potential energies that arise from chemical bonding situations or intermolecular attractions or repulsions.
The first law of thermodynamics says that ΔE = q – w
ΔE is the change in the internal energy of the system
q is the heat that has flowed into the system
w is the work that has been done by the system
It is fairly easy to see, when it is put in this way, that the first law is just a restatement of the law of conservation of energy.
So why do chemists, engineers, physicists, and geologists work with enthalpy H instead of internal energy E?
Well Enthalpy is defined by ΔH = ΔE + Δ(pV)
When a chemist does a reaction that produces a gas, or when a kettle is boiled in an open room, the system actually does work: the gas has to push back the surrounding air against its pressure to make room for itself. So for work at constant pressure, work done by the system = pΔV
We can put the two equations together for constant pressure conditions:
ΔE = q – w; w = pΔV = Δ(pV), and we will get ΔE + Δ(pV) = q, or ΔH = q
So, ΔH = q for the conditions that a chemist usually works with: a constant pressure environment (does not matter which specific pressure), and the system does no other work and has no other work done on it than the work of expansion.
ΔH is a modified internal energy designed to take account of work of expansion for the volume change of a system.
If a reaction is carried out at constant volume, then w = 0, and ΔE = q.
ΔH = ΔE + Δ(pV) will be rather greater than q if a gas is given off, because there will be a large increase in pressure in the closed vessel.