Set in a fictional dynasty during the Joseon era, a shaman from the Star Observatory witnesses a palace conspiracy and is pursued. She is saved by Lady Shin (Yang Mi-kyung), the wife of a Hongmungwan scholar. The shaman sees that the girl in Lady Shin's womb is the "Moon of Joseon"—noble and glorious—but that if she ever draws near the "Sun of Joseon," her entire family will be destroyed. To repay Lady Shin's kindness, the dying shaman entrusts her fellow shaman Jang Nok-young (Jeon Mi-seon) with protecting the child. Lady Shin gives birth to a daughter named Yeon-woo. Thirteen years later, Yeon-woo (Han Ga-in) meets Crown Prince Lee Hwon (Kim Soo-hyun) by chance, and he falls for her at first sight. Lee Hwon's half-brother, Prince Yangmyung (Jung Il-woo), whom he admires and relies upon, also deeply loves Yeon-woo, and his brother's feelings for her cause him great inner pain. Meanwhile, a conspiracy in the inner palace completely changes the fates of all three, and the shaman's prophecy comes true step by step. The love and hatred between two "moons" and two "suns" unfolds within the deep palace of Joseon... Adapted from the novel of the same name by Korean author Jung Eun-gwol, it set the record for the highest viewership ratings in Korea that year.