Heat convection is a type of heat transfer that occurs due to the mass motion of fluid because the molecules are moving apart as they heat up and accelerate.
As a result, air expands when heated and contracts when cooled, just like most other substances. The air is less dense than the surrounding matter because there is more space between the molecules, and hot air floats upward.
Heat convection occurs when the surrounding fluid of an object is heated.