Chang'e (嫦娥) is the moon goddess in Chinese mythology. While there are many stories of her in the legends, she is by and large most widely known for the tale that is considered the origin of the Mid-Autumn Festival.
Long ago, the earth was scorched by ten suns in the sky. The many suns made the earth unbearably hot, threatening the crops and lives of the people. A hunter, Hou Yi (后羿), fixed this problem by taking his bow and arrows and shooting down nine of the ten suns, leaving only one to warm the earth and provide its light. For his deeds, he was rewarded by the gods with the elixir of immortality.
Despite possessing the elixir, Hou Yi did not take it, as he did not want to be apart from his wife, the beautiful and graceful Chang'e. He kept the elixir in their house and they live together happily. However, one day, while Hou Yi was out hunting, his apprentice, Feng Meng, entered his house and tried to force Chang'e to give him the elixir of immortality. To keep him from getting his greedy hands on the precious elixir, Chang'e ingested it herself, then flew to the moon and made her residence there.
There are several versions of this story. In one, Hou Yi is so saddened and guilt-ridden about the loss of his wife that he offers fruits and cakes and then kills himself in his grief. In another, Hou Yi is an evil tyrant, and Chang'e steals the elixir to keep him from divinity or to escape from him. In yet another version, she takes the elixir of immortality out of pure selfishness.
Regardless of her reasons, Chang'e became the fabled moon goddess and is the central figure upon which the Mid-Autumn Festival was established. During this time, under the full moon, cakes and pastries are offered on open-air altars to Chang'e.