Les Misérables opens not with the protagonist, Jean Valjean, but in an anonymous French town of D—, where a Bishop known as “Welcome” or “Bienvenu” is astonishing the inhabitants with his modest ways, his commitment to the poor, and his unyielding acts of forgiveness. The Bishop is not necessarily a brilliant theologian but rather shows his character through his good works. One day, a shady, ominous-looking figure arrives in town, looking for a meal and a bed. Word gets around that this man is Jean Valjean, a convict recently released from the galleys—his yellow passport, a requirement for ex-convicts, betrays him—and everyone refuses to host him. Finally, a woman in the street tells the despairing Valjean to knock at the Bishop’s door. He does so, and the Bishop treats him kindly and cordially. That night, however, Valjean wakes up and, after a brief battle with his conscience, tucks the Bishop’s silverware and ornate candlesticks under his arm and runs away. The next day, he’s brought back by the police, but the Bishop claims that he had given Valjean these things as a gift, so he should be set free. Valjean is absolutely overwhelmed by this act. He heads away from town, struggling to understand how and why the Bishop didn’t obey the laws of judgment and revenge that seem, to Valjean, to define society. As he’s struggling with the new idea of mercy, Valjean comes across a small Savoyard boy named Gervais, and steals the young boy’s money from him. Suddenly, he’s stricken by what he’s just done—a reflexive act based in his own past—and he races around the area, attempting without success to find Gervais.
The novel’s focus moves to Paris, where a young, poor, and innocent woman named Fantine has arrived from the provinces to gain a living for herself. She’s fallen in with a group of youths, paired off between men and women, and led by Felix Tholomyes, a jovial young provincial man who’s in Paris to study but mainly to have a good time. Fantine, however, is sincere in her love for him, and unable to see through his act. At the end of their summer together, Tholomyes and his friends leave a note for the girls saying that they’ve been summoned back home and must return to reality. But Fantine is pregnant. After she gives birth to her child, Cosette, she knows that she must take desperate measures in order to care for her without revealing the socially stigmatizing fact of Cosette’s illegitimacy. Stopping at Montfermeil on the way to the factory town of M.-sur-M., she sees a woman, Madame Thenardier, watching her two children, Eponine and Azelma, play outside. Touched by this sight, she asks the woman to take care of her daughter while she works. Fantine promises that she’ll return in six months. Madame’s husband, Thenardier, haggles a higher monthly price for taking care of her, and Fantine sets off again. She arrives at M.-sur-M. and is given a job at a factory. However, people slowly grow suspicious of her lack of a family and her constant letter-writing to Montfermeil. Finally, one woman goes to Montfermeil herself and returns with the news of Fantine’s bastard child. The supervisor fires Fantine, and she is forced to take all kinds of menial jobs. Meanwhile, Thenardier continues demanding higher and higher sums for Cosette, lying about various sicknesses she’s had—while in reality the family has been using Cosette as their personal servant—until Fantine is ultimately required to prostitute herself.
One day Fantine is detained, after a dandy on the street torments her until she throws herself on him. The police inspector Javert brings her to the mayor, Madeleine, who was the one responsible for transforming M.-sur-M. from a poor village into a thriving factory town through new industrial methods he invented. The mayor is known for his generosity and kindness, his constant good works, his faith—and his commitment to the Bishop of D---, whose death he mourns profoundly. After hearing Fantine’s tale, to Javert’s shock, Madeleine tells him to let this woman go. Javert, who believes only in the authority of the law, leaves, fuming. He’s been suspicious of Madeleine ever since he saw him achieve a herculean feat, lifting a horse-cart off of a man named Fauchelevent and saving his life. The only man that strong whom Javert ever knew was a convict, Jean Valjean, who is now wanted for another theft against a Savoyard boy. Javert then finds out that Jean Valjean, now going by the name of Champmathieu, has been captured in the town of Arras. Javert tells Madeleine this story, and Madeleine grows pale, for Madeleine is none other than Valjean himself. Madeleine spends a sleepless night wondering if he should abandon the town—and, now, Fantine, who is desperately ill and has asked him to fetch her daughter Cosette—or sacrifice an innocent man. The next day, he decides to go to the trial anyway, still unsure of what he’ll say. But once there, he confesses in front of the entire courtroom that he is Jean Valjean, and offers various proofs. In the confusion that ensues, Valjean isn’t arrested, and he manages to slip back to his bank, where he withdraws a sum of half a million francs. He hides this in the forest of Montfermeil and then returns to M.-sur-M., where Fantine is at the point of death. Only then does Javert arrest Valjean and send him back to prison.
Not long after that, at a port in Toulon where convicts are responsible for cleaning the ships in harbor, one convict loses his balance and nearly falls into the sea, barely able to hold on to the side of the ship. Suddenly, with a crowd watching, another convict races over, climbs down to the other man, and carries him back up to safety. Shortly thereafter, this savior himself totters and then falls into the sea: the convict, Jean Valjean, is declared to be dead. This, however, is not true, and Valjean is able to swim underwater to safety. He travels to Montfermeil, where he comes across a small waif in the forest at night, carrying a massive bucket of water back to the Thenardiers. It’s Cosette, who leads him back home, where Valjean sees just how the family has been mistreating her. Valjean looks poor himself, so Thenardier doesn’t respect him, until Valjean buys Cosette an extravagant doll, transforming the way the Thenardiers look at him. Valjean pays Thenardier off and takes Cosette away with him to Paris. There, they spend several months in quiet happiness, as Valjean teaches Cosette to read and write and nurses her back from her state of wretchedness and near-starvation. Valjean becomes known as the poor man who gives alms, but one evening he gives money to a beggar and thinks he recognizes Javert in disguise. After growing suspicious that Javert is on his trail, Valjean takes Cosette and abandons their home. That night, he grows aware that Javert is following him through the streets of Paris, eventually leading a whole group of policemen behind him across the Seine and into the streets of the Right Bank. Finally, Valjean reaches an alley with no outlet, only a massive wall. With only a few minutes to spare before Valjean and his men corner them, Valjean uses his massive strength and a spare rope to hoist Cosette and himself up the wall, succeeding in losing Javert. They fall to the other side and encounter none other than Fauchelevent, whose life Valjean had saved, and who now works as gardener in the Petit-Picpus convent. Fauchelevent helps Valjean and Cosette sneak out of the convent and then reintroduces them to the prioress as his brother and niece. Cosette enrolls in the school, and they spend several happy years there until Fauchelevent’s death, at which point Cosette and Valjean move away to their own home.
Cosette and Valjean are accustomed to walking in the Luxembourg Gardens, where they often encounter a young man named Marius. Marius had grown up with his grandfather, Gillenormand, a somewhat ridiculous but cheery old man with royalist views. Marius’ father, Georges Pontmercy, had been a colonel in Napoleon’s army, which Gillenormand disapproved of, so after his mother’s death Gillenormand had raised Marius himself and forbidden his father from seeing him. Only after his father’s death does Marius learn how much his father loved him, and as he learns more about him, his political views begin to change radically. Finally, once his grandfather finds out just how loyal he’s become to his father and how liberal his politics have become, he turns Marius out. Marius gets involved with a group of leftist students, the Friends of the ABC in the Latin Quarter, including Courfeyrac and Enjolras. He continues his law studies but falls into abject poverty, moving into a house known as the Gorbeau hovel. Slowly, he becomes infatuated with the unknown girl who walks in the Luxembourg each day with her father.
Marius’s neighbors at the Gorbeau hovel are the Jondrettes, a wretchedly poor family. The husband Jondrette, rather than working, prefers to send plaintive letters to wealthy benefactors in order to ask for money. One day, Marius peers through a hole in the wall and is able to see the girl from the Luxembourg, with her father, together who have come to give alms to the Jondrettes. The Jondrette husband puts on an over-the-top act of desperation, and the girl’s father promises to return that evening with money for them. After they depart, Jondrette exclaims that he recognized that man, and he’ll take his revenge on him for good this evening. Terrified that the girl will come to harm, Marius goes to see a policeman—Javert—and tells him of the man’s plans. Javert prepares a sting for that evening. Marius witnesses the entire affair: Jondrette hires other criminals, traps the man in his room, and exclaims that he’s Thenardier, and he knows the man is the one who stole the girl (Cosette, though he doesn’t say her name) away from him. But the man is able to escape, and Javert captures Thenardier and his cronies.
Marius is still confused at the identity of the man and his daughter. He moves away from the hovel. But the Thenardier daughter, Eponine, has fallen in love with Marius. She knows he wants to see the girl, and so although it pains her, she finds him and shows him to the garden where Cosette often sits throughout the afternoons. Cosette recognizes Marius from the Luxembourg, and they begin to spend every afternoon together all throughout the spring, without Valjean finding out.
However, Eponine’s jealousy is such that she cannot bear for Marius to be happy with Cosette. She sends Valjean an anonymous note warning that he is not safe in the house. Valjean has begun to feel in any case that it would be safer for him and Cosette to go abroad, and he tells her that they are moving to London. In despair, Cosette writes a letter to Marius, who goes to see Gillenormand in hopes that his grandfather will, despite his anger at Marius, give him permission to marry. Gillenormand is thrilled to see Marius, but cannot find a way to show his emotions, and Marius ends up leaving, having failed to achieve that permission.
Meanwhile, it’s early June in 1832, and many people in Paris are distraught at the death of General Lamarque, an extremely popular politician whom the lower classes of Paris adored for his attention to social issues. Tensions are rising in the streets of Paris, and Courfeyrac and Enjolras, among others, are preparing to fight against the army, hoping to spark another revolution that will lead to social change. Marius is wandering around Paris in despair. He hasn’t heard back from Cosette, and decides he’ll die rather than live without her, so he might as well join the insurgents. They begin to create a barricade around the Corinthe tavern. What follows is a long battle scene, which lasts nearly the entire night. Meanwhile, Valjean finds a draft of a love letter written from Cosette to Marius. He’s utterly distraught, thinking that now he’ll lose her to another man. Then he intercepts a letter from Marius to Cosette, which was meant to be delivered the next morning, saying that he’s died on the barricades. Against his own will, Valjean goes to the barricades himself. There, Javert has been taken prisoner. Valjean asks permission to kill Javert himself, but instead of shooting him, he lets Javert go free. As the army descends on the tavern, killing all the insurgents who remain, Valjean finds Marius, deeply wounded, behind the barricade, and carries him away. There’s nowhere for them to escape, however, until Valjean catches sight of an iron grating. He lifts it off and they find themselves in the Paris sewer. Valjean carries Marius for hours through the sewers, growing increasingly exhausted and despairing that he’ll ever find a way out. Finally he emerges, only to come face-to-face with Javert, who had been pursuing Thenardier into the sewers. Valjean tells Javert he will surrender to arrest, but first asks permission to deposit Marius at Gillenormand’s, and to say goodbye to Cosette. As he ascends the stairs to Cosette’s room, he looks out the window and sees that Javert has disappeared. Struggling with Valjean’s mercy, and now his own, Javert is in total despair. He cannot find a way to reconcile his belief in authority and the law with this new system of mercy. He throws himself into the Seine, killing himself.
Gillenormand nurses Marius back to health, and loses all of his former pride. He and Valjean agree that Marius and Cosette may marry, and the couple passes several happy months together. Valjean eventually tells Marius about his past as a convict, and Marius in response slowly weans Valjean away from Cosette, until he can barely see her at all. However, as Valjean is nearing death, Marius finds out through various sources that Valjean had reformed and enacted many good works as the mayor of Madeleine; that he hadn’t killed Javert but had let him go free; and that it was Valjean who carried Marius through the sewers to safety and freedom. Marius and Cosette rush to Valjean’s bedside, where he dies, happy, next to Cosette.