The Earth does not lose its heat at night as quickly as the moon because the Earth has an atmosphere. If you don't know what the word atmosphere means, another way of thinking about it is a blanket around the Earth; a blanket that we can see through.