In 1945 Barcelona, a second-hand bookseller, Mr. Sempere, takes his son Daniel to the Cemetery of Forgotten Books for the first time. The Cemetery is a secret library about which only the city’s booksellers and literary figures know, that protects books at risk of fading away into oblivion in the real world. The young Daniel is awestruck by the size and scope of the library, and the possibilities for learning it contains. When told he can choose a book to take home, he wanders the library and finds Julián Carax’s The Shadow of the Wind, unsure if he’s guided by “chance or its more flamboyant cousin, destiny.”
Daniel sees on the book jacket that Carax is a native of Barcelona, but even his father has never heard of the author. When they consult another bookseller, the wealthy and well-connected Gustavo Barceló, he tells them that while no one knows exactly who Carax is, his books are becoming increasingly valuable because they have a habit of disappearing. Barceló offers to buy the book, but Daniel declines. In order to examine it, Barceló invites Daniel to his house, where Daniel meets, befriends, and falls in love with Barceló’s blind niece, Clara. In order to spend time around her, Daniel spends all his afternoons reading aloud to her in the apartment. His father, as well as the Barcelós’ kindly maid, Bernarda, are skeptical of his overwhelming devotion to an adult woman he will never be with.
Several years later, Daniel plans a sixteenth birthday party to which he invites Clara, but she never shows up. Upset, Daniel leaves the house to wander the city streets, where a terrifying stranger approaches him and demands to know where his copy of The Shadow of the Wind is. Daniel is worried that the stranger will hurt Clara, at whose house he left the novel, so he goes to retrieve it. Once in the apartment, he discovers Clara in bed with her music teacher, Adrian Neri, and feels incredibly betrayed. He brings the novel back to the Cemetery of Forgotten Books and hides it.
Freed from his passion for Clara, Daniel has more time for the normal activities of adolescence, like spending time with his best friend, Tomás. He and his father also take on another employee for the bookshop, a homeless man named Fermín who turns out to be an excellent salesman and good at finding rare books. Daniel begins to investigate Julián Carax’s past, visiting his childhood apartment building and pressing the caretaker and administrator for details about his family, as well as Nuria Momfort, the secretary of Carax’s publisher, who says she doesn’t know much about him. Meanwhile, a sinister police officer named Inspector Fumero turns up at the bookstore looking for Fermín, who was a political prisoner during the Spanish Civil War.
Daniel encounters Tomás’s older sister Bea at her university and is enthralled by her, even though as children they were enemies. She’s engaged to a young fascist soldier named Pablo, but seems unexcited about the prospect of marriage and agrees to meet Daniel. On their evening together, Daniel tells her everything he’s learned about Carax and shows her the Cemetery of Forgotten Books. He falls in love with her, although he knows her father would forbid a relationship with him.
Needing his investigative talents, Daniel confides his growing obsession with Carax to Fermín, who’s also interested. Fermín uncovers that Nuria was lying when she said she didn’t know Carax well. On Fermín’s initiative, they visit Carax’s school, where they meet his old friend Father Fernando. The priest tells them that Carax grew up in an abusive home and was mentored by the wealthy and powerful Mr. Aldaya, who took an interest in him and paid his private school tuition. Carax was friends with Aldaya’s son Jorge and fell in love with his daughter Penélope, even though this was forbidden by their different social classes. Javier Fumero, the son of the school’s caretaker, was also in love with Penélope, and tried to kill Carax when he discovered their affair.
Bea helps Daniel get inside the old Aldaya mansion, which her father’s real estate company owns. She figures out that the house was built by an eccentric millionaire, Salvador Jausà, whose servant and lover Marisela poisoned him and killed his wife. For the rest of his life, Jausà remained convinced that Marisela’s spirit lived in the house and tried various means of contacting it, giving the house its reputation for being cursed. Soon after, the Aldayas bought the house and moved in. After relating this tale, Daniel and Beatrice have sex in the house.
On advice from Father Fernando, Daniel and Fermín visit the hospice where Penélope’s devoted old governess Jacinta lives. Jacinta tells them that she’s always been guided through life by Zacarías, a supernatural spirit who appears in her dreams and predicts what will happen in her life. He guided her to the Aldayas, and Jacinta considered Penélope a daughter. Jacinta helped Penélope carry on a secret affair with Carax and explains that, with the help of Carax’s best friend Miquel, they planned to elope to Paris. However, right before the elopement, Mr. Aldaya found out about the affair and learned that Penélope was pregnant. He had Jacinta locked in a mental asylum, and when she’s finally released she can’t find any trace of Penélope.
On the way home, Daniel and Fermín run into Fumero, who beats up Fermín and warns them to stop looking into Carax’s past. Daniel takes his friend to the Barceló apartment to recover and tells the whole story to Barceló, who agrees to help him investigate. The next day, Daniel returns to the Aldaya mansion for another rendezvous with Bea. She promises to call him the next day, but he doesn’t hear from her for a week. When he finally calls the house, he realizes that her father has found out about their affair and is threatening to kill him.
In order to find out what Nuria really knows, Daniel visits her and announces he knows she’s been lying, but she won’t tell him anything. That night, she is mysteriously murdered, and the newspapers claim that a known criminal matching Fermín’s description committed the crime. Daniel’s father finally realizes that he and Fermín have gotten themselves into trouble, and he reproaches Daniel for having a role in Nuria’s death.
Nuria’s father gives Daniel a manuscript from her, which explains the truth about Carax. She met him in the 1930s and became his lover, even though he told her he would only ever love Penélope. She also met his friend Miquel, who fell in love with her, although she didn’t reciprocate. Miquel and Nuria became lovers out of their mutual loneliness and obsession with Carax.
Miquel told Nuria that Mr. Aldaya locked Penélope in her room for the duration of her pregnancy and forced her to give birth unassisted, after which she died. Miquel never told Carax this, because he knew it would upset him and he would try to fight Mr. Aldaya. Miquel spoke to Carax’s mother, Sophie, who confessed that she had an affair with Mr. Aldaya long ago and that Carax and Penélope were brother and sister.
Meanwhile Jorge, the only surviving member of the Aldaya family, sank into ruin. He fell in with Fumero, who used him as a pawn to entrap Carax and convinced him to duel with Carax in Paris, thereby driving Carax to kill Jorge and flee to Barcelona. When Nuria and Miquel heard about this from one of Carax’s friends, they waited anxiously for him to arrive and then begin searching the city for him. One night, Miquel found him at the old Aldaya mansion, but the police were on their trail as well. Miquel took Carax’s passport so that the police would shoot him instead, and was killed.
Afterward Carax becomes lovers with Nuria again but searches the city for Penélope until he discovers that her body is buried in the crypt under the Aldaya house. In rage and grief, he burns down the publisher’s warehouse that stores his books. In the fire, his facial features are burned and disfigured. He adopts an alter ego which he calls Laín Coubert, the name of the devil in one of his books. As Coubert, he tracks down and destroys all remaining copies of his work, as well as stealing to support himself and Nuria.
Carax/Coubert discovers Daniel’s copy of The Shadow of the Wind and admires the integrity he displays by refusing to give it up. As Daniel grows up, Carax keeps tabs on his activities, feeling that Daniel is like a young version of himself.
After reading the manuscript, Daniel is determined to find Bea and fight for her. He visits her house, where Tomás says angrily that she’s pregnant and has run away. Daniel finds her at the Aldaya mansion, where she’s already met and befriended Carax. However, Fumero soon shows up and Daniel and Carax have to fight him, eventually impaling him on the arm of an angel statue in the garden.
Daniel spends weeks in the hospital as a result of a gun wound sustained during the fight. Afterwards he marries Bea, who soon gives birth to a son named Julián. Ten years later, Daniel has settled down to run his father’s bookshop with Bea’s help. Carax has escaped to Paris and begun to write again under a new pseudonym. Fermín becomes the keeper of the Cemetery of Forgotten Books. In the last chapter, Daniel takes his own son to the Cemetery for the first time, just as his father brought him so many years ago.