Hot objects and buildings transfer energy to their cooler surroundings by conduction, convection and radiation. This transfer is usually unwanted, so we use thermal insulation to reduce the rate at which it happens.
To reduce conduction, use materials that are poor conductors, such as foam, wool or fibreglass. A thicker layer slows the transfer more. Trapped air is a very good insulator because air is a poor conductor. To reduce convection, stop the air or liquid from moving. In small pockets of trapped air the air cannot circulate, so insulation made of fibres or foam reduces both conduction and convection. A lid on a container stops warm air rising away.
To reduce radiation, use shiny, light-coloured surfaces. Shiny surfaces are poor emitters and good reflectors of thermal radiation, so they send energy back towards the object.
These ideas are used in a house. Loft insulation and cavity wall foam trap air, so energy is conducted slowly and warm air cannot rise by convection. Double glazing has a gap between two panes, and draught-proofing stops warm air leaking out. A vacuum flask has a vacuum between double walls, which stops conduction and convection, and silvered surfaces which reduce radiation.