1968 – Mill Valley, Pennsylvania – Accompanied by aspiring writer Stella Nicholls, teenagers Chuck Steinberg and Auggie Hilderbrandt prank school bully Tommy Milner and his cronies on Halloween night. Tommy chases the trio to a drive-in movie theater where Stella, Chuck, and Auggie hide in a car belonging to Ramon Morales, an out-of-towner who is secretly dodging the draft. Stella and Ramon take an interest in one another.

When he finds the three friends, Tommy insults Stella by suggesting her mother left her father Roy because of Stella. He also demeans Ramon before the manager forces Tommy to leave.

Stella, Chuck, Auggie, and Ramon decide to spend the rest of the night investigating the abandoned and reportedly haunted Bellows Family mansion. After breaking in and exploring the house, Stella recounts the legend of Sarah Bellows. Sarah’s family was among Mill Valley’s first settlers, and they made their fortune via a paper mill. Sarah was a supposedly insane writer who was kept locked away in a hidden room as well as erased from all family portraits. Sarah was said to have poisoned local children before hanging herself with her own hair in 1898. Legend has it you could come to the house and ask Sarah to tell you a story through the wall of her room, but it would be the last story you ever heard.

While hiding in a closet to scare Auggie, Chuck briefly sees the surrounding room inexplicably revert to 1898. Chuck sees an old woman, Sarah Bellows’ mother, with a Doberman before blinking back to reality.

Stella and Ramon find the secret room where Sarah was imprisoned. Stella recovers the storybook in which Sarah supposedly wrote terror tales using the blood of children.

Tommy locks Stella, Ramon, Chuck, and Auggie in Sarah’s room with Chuck’s sister Ruth. However, the door supernaturally unlocks after Stella asks Sarah’s ghost to tell her a story.

Once outside, Ramon discovers that Tommy vandalized his car. Stella offers to let Ramon sleep in her basement for the night.

When he learns about her writing, Ramon recommends that Stella move to the city to become a successful author. Stella insists that she cannot leave her emotionally troubled father alone.

Alone in her bedroom, Stella sees a story called “Harold” being supernaturally written about Tommy in blood in Sarah’s book. At the same time, a scarecrow named Harold comes alive on Tommy’s family farm and kills the boy by turning him into a scarecrow.

Police Chief Turner harasses Ramon at the mechanic the next day. Chief Turner mentions Tommy’s disappearance and insinuates that Ramon could be a suspect since he is an outsider.

Stella shows Chuck and Auggie the new story that appeared in Sarah’s book. Chuck reveals what he saw while in the Bellows mansion closet. Auggie dismisses their claims as a ghost story.

Stella tells Ramon that she believes the new story and Tommy’s disappearance are connected. Stella and Ramon investigate Tommy’s farm and discover Tommy took Harold’s place as the scarecrow. However, Ramon doesn’t believe Stella’s suspicion.

Stella returns the book to the Bellows house. Inexplicably, the book shows up in Stella’s bedroom when she returns home.

Ramon realizes the book’s curse is real when he and Stella see a story called “The Big Toe” being written about Auggie. Stella radios Auggie with a frantic warning to not eat anything. Auggie still eats a pot of stew found in his fridge and nearly swallows a toe along with other body parts. A corpse shambles toward Auggie demanding the return of her toe. Auggie hides under a bed, but the corpse pulls Auggie into the darkness and he disappears. When they arrive, Stella and Ramon find only fingernail scratches in the floor.

Stella blames herself for inciting Sarah’s curse. She and Ramon meet with Chuck and Ruth to explain what happened to Auggie. Ruth leaves in disbelief. The remaining three friends try burning Sarah’s book, but it is unaffected by fire.

Stella, Ramon, and Chuck research Sarah Bellows in the newspaper archives. They learn that one of the family’s caretakers and her daughter, Louise ‘Lou Lou’ Baptiste, were believed to be involved in voodoo. They also learn everyone in Sarah’s family mysteriously vanished within one year of Sarah’s death. Stella double checks the book and sees that Sarah’s family members were victims in other stories.

A story called “The Red Spot” starts writing with Ruth as the central character. Stella, Ramon, and Chuck race to the school where Ruth pops a massive spider bite pimple that releases hundreds of spiders. Stella sees Sarah’s shadow orchestrating the event before Ruth is carted away in an ambulance and committed to an asylum.

Stella, Ramon, and Chuck visit Lou Lou. Lou Lou denies that her mother taught black magic to Sarah and instead suggests that Stella made Sarah angry by taking the book.

Stella, Ramon, and Chuck sneak into New Pennhurst Hospital to examine Sarah’s medical history. Fearful of a ‘red room’ because of a terrifying dream he had, Chuck enters a separate wing while Stella and Ramon research Sarah’s records.

Records reveal that Sarah’s brother Ephraim was her supervising doctor. Through a wax cylinder audio recording, Stella and Ramon discover Sarah’s family conspired to have her tortured with shock treatment because she found out the family’s paper mill poisoned the town’s children through mercury in the water. The Bellows made Sarah their scapegoat and imprisoned her in the house as punishment.

The book begins writing a story titled “The Dream.” At the same time, a Pale Lady shambles toward Chuck in another hallway before absorbing him into her stomach through an embrace.

Stella and Ramon are arrested following the hospital break-in and Chuck’s disappearance. Fearful that the book will target her next, Stella tearfully calls her father Roy with a cryptic warning that she may vanish. While consoling Stella, Roy explains that it wasn’t her fault that her mother left them.

Refusing to entertain their claims about the book, Chief Turner outs Ramon as a draft dodger and locks him in a cell with Stella. The power goes out in the police station as the book begins writing “Me Tie Dough-ty Walker” with Ramon as the central character.

Starting with a decapitated head, body parts fall into the station through its chimney. The body parts assemble into The Jangly Man, who kills Chief Turner.

Stella and Ramon escape the station with the book. Stella goes back to the Bellows mansion while The Jangly Man pursues Ramon.

At the Bellows house, Stella screams that she knows Sarah is innocent and begs Sarah to stop telling stories. Stella inexplicably becomes Sarah Bellows as she is transported to 1898 inside a story titled “The Haunted House.” Lou Lou momentarily helps Stella hide, but Stella is ultimately captured and imprisoned by the Bellows Family.

Still pursued by The Jangly Man, Ramon enters the house in 1968. Deducing what happened to Stella from her dropped book and eyeglasses, Ramon shouts across time for Stella to tell Sarah the truth.

Stella confronts Sarah’s ghost in the hidden room. Stella explains that she understands Sarah was a victim who was unfairly turned into a monster. Stella vows to tell people Sarah’s true story, but Sarah must stop her rage first. Sarah gives Stella her pen. Stella uses her blood as ink to begin writing Sarah’s story. Sarah screams and vanishes. The Jangly Man also disappears. Stella and Ramon reunite.

In the aftermath, Stella wins a writing contest with her story about Sarah’s tragic history. Ramon joins the army. Stella promises to write to Ramon every day. Accompanied by her father and Ruth, who was released from the asylum, Stella goes on the road in search of a way to bring Chuck and Auggie back.