The School for Good and Evil In the village of Gavaldon, Agatha and Sophie have grown up as best friends for different reasons. The awkward and morbid Agatha is in the attentions of the beautiful but vain Sophie, who hopes that it will raise her chances to get selected to attend the School for Good, one of two legendary academies that prepare children to become fairy tale characters, the other being the School for Evil. Every four years, two children are taken from the village to be enrolled in either school. The children are never returned, but appear in storybooks that come yearly.
When the two girls find themselves whisked away by the mysterious Headmaster of the schools of Good and Evil, known the School Master, Sophie is ecstatic until she realizes that she has been placed in the School for Evil (To become Nevers) and Agatha is in the School for Good (To become Evers). She tries to switch places with Agatha many times to of no avail. Agatha soon finds she can grant wishes for people and nearly turns a gargoyle into a little boy, but it is killed. All she wants, however, is to return home with her friend. Agatha learns that the School Master and his brother were at war and that one of them died in the process, and the dying brother enchanted the Storian, a magical pen, to keep the Woods in balance.
The girls break into the mysterious School Master's tower and see the Storian begin to write their story. The School Master gives them a riddle they are unable to solve for some time. Agatha realizes "The thing Nevers can never have and Evers can't do without" is love.
Knowing that a kiss from true love will end a story, Agatha helps Sophie charm Tedros, the son of King Arthur, into asking her to the Ever Ball by disguising herself as a cockroach and helping Sophie through her classes so she ranks #1. This eventually backfires when Tedros discovers what is going on at the Trial by Tale. Agatha protects Tedros when he is to die, calling out Sophie's name. Sophie plummets into irrational rage and Nemesis Dreams. Sophie then uses her ability for evil to take revenge on Tedros and eventually Agatha, who is revealed to be Sophie's Nemesis that she must destroy. She tries to enlist the Never students in her task, but they are initially reluctant to take part in all of Sophie's revenge. In the evil moat The School Master hurls the Storian, meaning to kill Agatha, but Sophie is speared instead and dies from her wounds. Agatha kisses Sophie, bringing her back to life. Agatha chooses her ending with her best friend/nemesis ins tea of her soon discovered prince, Tedros, and she and Sophie both return to their village.
When the story, The Tale of Sophie and Agatha is published to the village, the last page ends with a picture of a prince who looks a lot like Tedros walking away, his back facing the page, and it says, They didn't need princes in their fairytale at all.'