After many centuries of disciplined training in Taoism whilst living in a cave on Mount Emei, the protagonist Bai Su Zhen, with the help of a heavenly immortality pill, transforms herself from her original form as a snake into human form, en route to seek immortality on her quest for divinity, guided by the Mother of Mercy, Guan Yin.
She then meets and defeats Xiao Qing ("Small Green") in combat, and chose mercy rather than ending Xiao Qing’s life. Xiao Qing then transforms into a female maiden and swears her loyalty as Bai’s servant in return for sparing her life (though they become close like sisters). Xiao Qing, like Bai, had originally been a serpent.
When she was just a young snake, Bai had been saved from being killed for her snake gall (an ingredient used in traditional Chinese medicine) by a young cow-herd. One of the reasons she entered the human world was to repay him. Guan Yin guided this endeavor by telling her that they would meet on Tomb Sweeping Day (holiday for visiting and sweeping ancestral graves) near the West Lake. Bai and Xiao Qing finds the descendent/reincarnation of that young cow-herd as in Guan Yin’s premonition. Hanwen (aka Xu Xian) went for a walk around West Lake after visiting the grave of his deceased parents. Bai and Xu Xian meet on the Broken Bridge and it is love at first sight.
In this life Hanwen works in a pharmacy and studies medicine. Because Hanwen had saved Bai in a previous life, she wishes to repay him. The two fall in love, marry, have a child, and are pursued all along the way by a religious zealot, Fa Hai. Fa Hai believes that a demon is always a demon and can never become good and belongs not in the human world hence his dogged pursuit. Bai has a child with Hanwen after their marriage. To save that child she agrees to be imprisoned in Lei Feng Pagoda (which literally means thundering wind tower), a symbol of the tomb.