The earliest written version of "Hansel and Gretel" was published by Italian poet and courtier Giambattista Basile in a posthumous release of his collection "The Tale of Tales," or "Entertainment for Little Ones" in 1634.
The most well-known version was written by German scholars Jakob and Wilhelm Grimm, first in 1812 and then in revised editions in 1819 and 1857. Prior to the written versions, "Hansel and Gretel" and many other fairy tales were passed down orally for years. Contemporary folk scholars believe that the tale dates back to the Middle Ages, when disasters such as famine, war and plague caused some parents to abandon their children. The brothers Grimm adapted their version specifically for middle class patrons during the 19th century, sanitizing some of the darker themes.