Easy question! It’s because hot air is less dense than cold air. Except that things aren’t really this simple.
How does hot air know its own density and the density of the cold air that surrounds it? For that matter, how does hot air know which way is up? You might say that hot air isn’t sentient (it doesn’t have the ability to know anything) so these questions are meaningless. But the question remains: why does hot air rise?
Answers that mention density and buoyancy are fine when there is a surface separating the object from its surrounding fluid but no such boundary exists for hot air. In this case, the answer is linked to energy. The temperature of a substance depends on how much energy it stores: hotter gases store more energy than colder gases because each particle has a higher velocity. (For the sake of simplicity, we will say that there is one specific velocity that is associated with each temperature.)
If a particle has greater velocity than another particle then it can move further in any direction in a given time. Most importantly, it can move further upwards and do more work against the gravitational field. Think about throwing a ball; if it is thrown with a low velocity it will move up only a short distance but if it is given a greater velocity it will travel higher. In the case of gases, colder particles with less velocity are displaced by the upwardly-moving particles and collect underneath. This results in the hot air rising and cold air sinking, as is commonly observed.
It is still true to say that a hotter gas will expand to occupy a greater volume and will therefore possess lower density than a colder gas, assuming that the pressure of the gas stays constant, but the cause of the expansion is an increase in particle velocity and the resulting drop in density is merely an effect of this change in energy.
So why does hot air rise? Because the particles in hotter gases have more kinetic energy than those in colder gases.
