Like many other holidays, Halloween has evolved and changed throughout history. Over 2,000 years ago people called the Celts lived in what is now Ireland, the UK, and parts of Northern France. November 1 was their New Year's Day. They believed that the night before the New Year (October 31) was a time when the living and the dead came together.
More than a thousand years ago the Christian church named November 1 All Saints Day (also called All Hallows.) This was a special holy day to honor the saints and other people who died for their religion. The night before All Hallows was called Hallows Eve. Later the name was changed to Halloween.
Like the Celts, the Europeans of that time also believed that the spirits of the dead would visit the earth on Halloween. They worried that evil spirits would cause problems or hurt them. So on that night people wore costumes that looked like ghosts or other evil creatures. They thought if they dressed like that, the spirits would think they were also dead and not harm them.
The tradition of Halloween was carried to America by the immigrating Europeans. Some of the traditions changed a little, though. For example, on Halloween in Europe some people would carry lanterns made from turnips. In America, pumpkins were more common. So people began putting candles inside them and using them as lanterns. That is why you see Jack 'o lanterns today.
These days Halloween is not usually considered a religious holiday. It is primarily a fun day for children. Children dress up in costumes like people did a thousand years ago. But instead of worrying about evil spirits, they go from house to house. They knock on doors and say "trick or treat." The owner of each house gives candy or something special to each trick or treater.