The average temperature of the Earth is maintained fairly steady by the atmosphere. It prevents a sudden increase in temperature during daytime and slows down the escape of heat into the outer space at night. It also acts as a blanket covering the Earth.