Legend has it that during the reign of King Jayavarman VII, a monk came back unscathed from Hell. He brought the message from the deceased that they could be freed from suffering if their relatives offered foods and alms to monks.
Pchum Ben dates back to the Angkorian period when people followed animism. Buddhism replaced animism, but since respect for ancestors was also a Buddhist belief, this custom remained.
Pchum Ben bears many similarities to the Taoist Ghost Festival that originated during Mahayana times and is still celebrated in many Asian countries.