During the opening credits, we see presumably Mary Shaw's hands building "the perfect doll".
After a few moments of showing affection for each other, Jamie Ashen and his wife, Lisa, receive a package in the mail. In this package lies a ventriloquist dummy. After a while of observing and joking around with it, Jamie heads out to get dinner for him and Lisa.
Back at their apartment, Lisa sets up the doll underneath the covers of her and Jamie's bed in order to frighten Jamie when he returns home. After some strange occurrences following doing this, including the radio's sound becoming distorted for a moment and the tea kettle whistling, Lisa ventures back into the bedroom and is murdered by an unseen entity.
Jamie returns with a rose and dinner in hand and discovers the tea kettle whistling. He hears Lisa's voice which lures him into the bedroom. On the way there, he sees a pool of blood. Worried, he walks into the bedroom and discovers Lisa's body underneath the covers where the doll should've sat, her mouth ripped open and her tongue removed, causing a disturbed Jamie to stumble back in horror.
At the police station, Detective Jim Lipton talks to his colleague about Jamie before actually confronting him. Now confronting Jamie, Lipton subtly tells him that he believes Lisa's death was caused by him. Jamie becomes, understandably, offended by this and begins mentioning the doll and how it arrived only moments before she was killed. Lipton becomes annoyed with Jamie for mentioning an inanimate object whilst talking about a murder case. Jamie is excused by Lipton.
Jamie heads back to the crime scene at his home and grabs the doll. Before taking off, he notices a little tear in the velvet interior of the case. Once he rips it open, he discovers a drawing of a woman called Mary Shaw and the same doll that arrived in the mail. Inferred by the caption below the drawing, Mary was the owner of this doll and had an act in which she practiced ventriloquism with it. Following seeing this, Jamie sets off to his home town, Raven's Fair, to find answers.
Jamie first stops at Edward's, his father's, house. The gatekeeper lets Jamie onto his father's property through the gate. Jamie pulls up to the house and walks up to the front door. A woman called Ella answers the door and apologizes for his loss. She then reveals herself to be his newest stepmother. Jamie enters the house and argues with Ella when she says that his father was a changed man. His father, whom of which is surprised by Jamie's arrival, is in a wheelchair. Jamie asks Ella what happened to which she responds that Edward had a stroke. Jamie becomes upset that he wasn't informed to which Edward responds that Jamie never returned his calls telling him that he had had a stroke. After this discussion, Jamie questions him about the doll. When the Mary Shaw poem is brought up, Ella tells Jamie that it's simply a meaningless old ghost story. On the way out, Jamie argues again with Ella about his father. Jamie mentions his past three mothers and what his father made them do (his biological mother and his first stepmother committed suicide and his second stepmother left).
Jamie sets off to see Henry Walker at the funeral home to discuss coffin options for Lisa. Back at his motel at night, Jamie looks at a photo of Lisa before flicking the lights off and rolling over. He wakes up to see the dummy, before on a chair, now at the side of his bed. After the doll mutters Jamie's name, the ghost of Mary Shaw appears by the window and is illuminated by the flashing lights of the motel sign. Jamie flicks the light on and, sure enough, Mary disappears and the dummy appears back on the chair.
Back at the funeral home, the coroner, Henry Walker, is about to take a photo of Lisa's corpse when he stumbles back in shock and confusion, obviously frightened. Henry then hears his wife, Marion, mumbling down in their crawl space. After a brief moment of talking to Marion, Henry successfully convinces his clearly terrified wife to exit the crawl space and go back to bed. Before heading to bed himself, Henry snaps a photo of Lisa's corpse.
At Lisa's funeral, a solemn Jamie puts a rose on her gravestone. Afterward, Jamie wanders into the woods and is confronted by Marion whom of which tells him that he must "bury the doll" before her husband pulls her away and takes her home. Jamie glances behind him and sees Mary Shaw's grave, telling Jamie where the doll must be buried. He sets off back to his motel room, grabs the doll, and finds small writing on the back of its neck, revealing that the doll's name is Billy.
Jamie heads to Mary's grave which is surrounded by many other smaller graves with different names on them (they belong to Mary's other dummies that were buried with her), and finds Billy's. After seeing it's head move and burying it, Jamie gets back in his car and drives back to his motel. Unexpectedly, Jamie sees two familiar faces: Billy's and Detective Lipton's. After Lipton confronts Jamie about supposedly having taken Billy, a piece of evidence at Lisa's crime scene, and burying it to, as Lipton again slightly hints, get rid of the evidence to look innocent, Lipton goes to his motel room and takes Billy with him.
In the morning, Jamie snatches Billy from Lipton's vacant motel room and heads to the funeral home to seek answers from Henry. After showing Billy to him, Henry sits Jamie down and tells him of his past. According to Henry, decades ago, Mary Shaw worked as a ventriloquist. Henry begins to tell Jamie everything he remembers of Mary Shaw.
We are given the first flashback of Henry's story. One day, Henry went to a massive theater where she was going to perform her act. Once she began it, a young boy called Michael said that he could see her lips moving. After a few moments of Mary screaming at the boy through Billy, everything quieted down and Mary told the boy, "Now, who's the dummy?"
Apparently, the boy went missing shortly afterward. Mary was killed shortly after his disappearance by an unknown person or people. Then, Henry begins saying how in Mary's will, she not only asked to be buried with all of her dolls, but she asked to transform into a doll herself.
We are given the second and last flashback of Henry's story. After Henry's father, Richard, performs the procedure down in the basement of the funeral home, a younger Henry creeps down into it at night a bit later. He peeks into Mary's casket and the table breaks as he does so, sending both him and Mary's corpse down to the floor. After falling to the ground, Henry meets Mary face-to-face, causing Henry to crawl backwards to the wall. After a moment of looking for Mary's now lost corpse, he spots her floating in mid-air, only Illuminated by the huge lightning flashes, and with a huge grin on her face. Henry covers his mouth to prevent himself from screaming as his father comes in and flicks on the light, revealing that Mary is now back on the ground.
Back in the present, Jamie grabs his things and heads off to the theater Henry was mentioning, ignoring Henry's warnings to keep away from it. It cuts to Lipton with a shovel by Mary's grave. Judging by his dialogue, he seemingly has the intention to dig up all of Mary's dolls to see if they are still there or if Jamie took them. It then cuts to Jamie arriving at the theater (which is separated from Jamie by a lake because the connecting bridge collapsed). Jamie steps into a canoe by him, rows to the theater's entrance, and enters the theater. Jamie climbs up the ladder behind the stage and shortly after stumbles into Mary Shaw's old dressing room. Upon investigation in Mary's old dressing room, he discovers that Michael's last name was Ashen in a newspaper article he finds in an old scrapbook (which is filled with other newspaper articles and pages upon pages of a plan to make "the perfect doll") and a hallucination of Mary's corpse sitting in a chair behind him. Jamie exits the theater.
Back at the funeral home, Henry catches Marion talking to Billy. Henry snaps at her and grabs the doll, taking it into the preparation room. He then hears Marion's cries from in the crawl space. Henry apologizes for snapping at Marion and ventures into the crawl space to get her out. He soon realizes that Marion wasn't in the crawl space and that it was a plan set up by the ghost of Mary Shaw to take his tongue, and take it, she does.
Later at night, Jamie goes back to his father's house and confronts his father at the dinner table, who is accompanied and being fed by Ella, about lying to him about Mary Shaw. His father says that he only did it to protect him from the truth. He then admits that Michael Ashen was his great uncle and that he was murdered by Mary Shaw. A brief flashback is seen of Jamie's relatives cutting out Mary's tongue. Jamie says he's going to end Mary's wrath once and for all and turns to exit the house, but is met by Lipton at the door. Lipton begins accusing Jamie of stealing every doll from Mary's grave. This is because when he checked all of the dolls' graves, he discovered that every single coffin was vacant. After they argue for a moment, Ella hands Jamie the phone, saying that the person who called for him said it was urgent. Henry's voice on the other line tells Jamie to head back to the theater to meet him because he has proof Jamie didn't murder Lisa. Jamie attempts to do this and struggles with Lipton for a bit, but ultimately gets to his car and makes his way to the theater. Lipton follows after him.
Jamie arrives at the theater, exits his car, grabs his lantern, rows across the lake in the canoe, and enters the theater. Lipton arrives and does the same. After following Henry's voice up into Mary's dressing room, Jamie is met by Lipton, whom of which is now armed with a loaded shotgun. Jamie and Lipton venture into an secret room that is hidden cleverly (the walls between the entrance to the secret room are the same texture, creating camouflage and therefore making it difficult to see that it's a doorway), but not before Jamie warns him not to scream. Upon entering the dilapidated room, they discover a wall of dolls hidden behind drapes, filled with cases of the missing dolls Lipton didn't find when digging up their coffins. The only doll missing is Billy, whom of which was left at the funeral home. They also discover Michael Ashen's rotting corpse strung up and turned into a human puppet. When Lipton asks about it, Jamie tells him simply that it's a family member that was lost long ago.
Lipton says that Henry isn't here and tries to get Jamie out of the room when Henry's voice from across the room speaks. After looking in the direction of his voice, they discover a clown doll sitting on a rocking chair near the wall of dolls. Jamie calls out Mary's name twice to which the doll, being controlled by the ghost of Mary Shaw, responds that he is clever. Lipton begins realizing that Jamie was telling the truth now. Jamie then asks what her goal is to which she responds that she wants to murder everyone who killed her. Jamie then asks why she killed Lisa, despite the fact that she and her relatives had no involvement in her murder. Mary gets Jamie to move close to the her, despite Lipton effort to hold him back. Mary responds to Jamie that he wasn't the last of the Ashen bloodline and that Lisa was killed because she was pregnant with his child. A disturbed Jamie then has his face licked by Mary's long, disfigured tongue through the doll's mouth. As Jamie stumbles backward toward Lipton, Mary stands up, holding the doll. A doll from the wall forms Mary's face and starts screaming. Lipton shoots it as another doll does the same thing. Lipton shoots this doll and another before Jamie throws his lantern at the wall, lighting it on fire. Before leaving with Lipton, Jamie notices Billy's empty case and realizes that one more thing must be done: Billy must be destroyed as well.
Jamie stands up and follows Lipton into Mary's dressing room. They then run into the long corridor connecting Mary's dressing room to the backstage area. Mary emerges from the end of the hallway, only illuminated by the moonlight. Jamie and Lipton continue to run. Mary continues to float down the corridor. Jamie and Lipton start running on the overhead bridge above the stage. The screws holding the bridge in place unscrew, turning it onto its side suddenly, sending Jamie and Lipton down. Jamie grabs onto the bridge at the last second whilst Lipton is sent flying downward. Lipton screams as he falls, allowing Mary's ghost to swoop in, grab him, and send him through the curtains. Shortly afterward, Lipton, missing his tongue and reaching out as if to plead for mercy, falls down to floor, dead. Lipton's phone falls out of his pocket and begins buzzing. Still alive and shocked from what just occurred, Jamie pulls himself up onto the bridge, being careful not to make the rest of the bridge collapse, and is met by the ghostly face of Mary Shaw smiling evilly at him. A terrified Jamie pushes away from her, sending him down off the bridge. In mid-fall, he nearly screams, but covers his mouth just in time and falls through the fragile floorboards into the cold lake water.
After swimming underneath the theater and bumping into various old mannequins, Jamie swims away from the theater and to the other side of the lake where his car is parked. He then gets in his car and drives to the funeral home to retrieve Billy. Upon arriving, he discovers Marion holding Henry's corpse. Determined to end Mary's wrath, Jamie asks a disturbed Marion where Billy is. Marion responds that his father took it to which Jamie becomes confused. Jamie then tells Marion that his father is in a wheelchair. Marion insists that it was his father so Jamie leaves her and heads to his father's house.
On the way to his father's house, it begins to rain heavily. Jamie pulls up in front of Edward's house and enters. He heads up the stairs and into the room where he met his father again. He discovers Billy covered up in a baby carriage. Just then, Mary Shaw bursts through the window and begins floating over to Jamie. Just moments before Mary Shaw reaches him, Jamie grabs Billy and throws him into the fire, sending a screaming Mary back through the window and into the rainy night.
Breathing heavily, Jamie stands up and notices his father sitting in the corner of the room. Once he gets closer, Jamie notices that his father isn't moving. Upon closer inspection, a horrified Jamie discovers that the majority of Edward's back has scraped out and is being replaced by a wooden stick. We are given flashbacks of Edward first talking to Jamie again whilst Ella stands behind Edward. We see Ella twisting the wooden pole to control Edward's movements and acting nervous, even gulping. We are given another flashback of Edward speaking to Jamie at the dinner table shortly after Henry's death. Again, Ella is seen controlling Edward. The food which Edward is fed by Ella drops down to the bottom of his empty stomach. We see the final flashback with contains Jamie studying the scrapbook he finds in Mary Shaw's dressing room when first entering the theater. As if we are shown his alternate actions, he flips a small piece of paper taped to a page with the words "the perfect doll" on it. Sure enough, on the opposite side of the piece of paper, we see Ella's face. Back in the present, Ella appears right beside Jamie. She then repeats the same line she said to Michael Ashen in the old theater to Jamie: "Now, who's the dummy?" The lightning from outside illuminates Ella's face showing Mary Shaw's face instead. Confused, angry, and terrified by the reveal, Jamie can't fight his emotions and screams out a bloodcurdling, "No!" This allows Mary to take his tongue, killing off the last Ashen. Mary's revenge has now been fully enacted.
The final few shots of the film are various deceased characters' faces being shown (Lisa, Henry, Lipton, Edward, and Jamie's) as well as Ella's (after all, she's "the perfect doll") in Mary's scrapbook, all turned into human puppets as Jamie repeats the famous Mary Shaw poem. The final shot of the film is the camera zooming out of the scrapbook and Mary Shaw shutting it before the screen cuts to black, revealing the closing credits.