The origin of the festival is disputed, and there are both pagan and Christian practices that have evolved into what Halloween is like today.
Some believe it originates from the Celtic pagan festival of Samhain, meaning 'Summer's End' which celebrated the end of harvest season.
Gaels believed that it was a time when the walls between our world and the next became thin and porous, allowing spirits to pass through, come back to life on the day and damage their crops. Places were set at the dinner table to appease and welcome the spirits. Gaels would also offer food and drink, and light bonfires to ward off the evil spirits.
The origins of trick or treating and dressing up were in the 16th century in Ireland, Scotland and Wales where people went door-to-door in costume asking for food in exchange for a poem or song.
Many dressed up as souls of the dead and were understood to be protecting themselves from the spirits by impersonating them. More about that below.
The Christian origin of the holiday is that it falls on the days before the feast of All Hallows, which was set in the eighth century to attempt to stamp out pagan celebrations. Christians would honour saints and pray for souls who have not yet reached heaven.
Celts dressed up in white with blackened faces during the festival of Samhain to trick the evil spirits that they believed would be roaming the earth before All Saints' Day on November 1st.