Trick-or-treating, the practice of costumed children going door to door to receive candy on Halloween, arose in North America during the 1920s. Children would threaten to commit mischievous acts, or "tricks," upon residents if they did not give treats. Historians trace this act to the ancient Celtic practice of making food offerings to the dead and dressing in animal-skin costumes to scare evil spirits away on Samhain, which took place on October 31, the day before the Celtic New Year.
Around the year 800, the Catholic church took over the pagan holiday Samhain and turned it into "All Saints' Day," also known as "All Souls' Day" or "All Hallows Eve." During the Middle Ages, poor people visited the homes of the wealthy to receive sweet-tasting cakes, referred to as "soul cakes," in exchange saying a prayer for the residents' dead relations. This practice, referred to as "souling," was later taken over by children who would go to homes asking for food, money or ale in exchange for a song or prayer.
Based upon the practice of souling, people in the United Kingdom developed the practice of "guising," a term derived from disguising, in the 19th century. Children dressed up and went to their neighbors' homes to beg for fruit or money. In exchange for these treats, children performed entertaining acts for their neighbours, such as singing a song or telling a joke. Historians believe that Irish and Scottish immigrants brought these customs to North America during the 19th and 20th centuries. The custom eventually evolved into trick-or-treating.