Groundhog Day is based on the festival known as Candlemas. This celebration represents the end of the Christmas cycle (forty days after Christmas) and marks the Presentation of the Lord in the Temple. Formerly, Candlemas honored the Purification of Mary after the birth of Christ. In Europe, Candlemas was combined with ancient pagan candlelighting ceremonies intended to rejuvenate the fields before planting crops.
This custom was brought to America by the Pennsylvania Dutch (German settlers) who believed that all hibernating animals come out to check on the weather. If the animal saw its shadow, then six weeks of bad weather would follow and the animal could go back to sleep. However, a cloudy day meant that spring was coming soon and the weather until then would be moderate.
In the United States, the most famous hibernating animal turned weather forecaster is Punxsutawney Phil who lives in Gobbler's Knob. Phil is over 100 years old and made his first weather report on February 2, 1887. His forecasts are recorded in the Congressional Record.