Told in the voices of multiple first-person narrators, Trash follows three boys who live in Behala, a third-world shantytown next to a garbage dump. Rather than attend school, Raphael, Gardo, and Rat (Jun-Jun) pick through the trash hoping to find anything they can sell to help feed themselves and their families. Often they only find stupp—human excrement wrapped in paper—because many people don't have toilets.
One day Raphael finds a wallet containing a map, a key, cash, and an ID card belonging to a man named José Angelico. That night, the police come to Behala to ask if anyone has found the wallet. They offer a cash reward of ten thousand pesos, and one hundred a day for searching for it. Raphael keeps quiet about the wallet, knowing it must be valuable if the police want them. Gardo and Raphael hide the wallet at Rat's, knowing the police might search their homes. Rat lives at the bottom of a disused conveyor belt once used for bringing trash out on top of the piles. Rat knows the key is for a locker at the Central Station, so the boys set out to open it. They recover a letter addressed to a prisoner named Gabriel Olondriz. There is a slip of paper with a code of numbers on it.
The boys use the computer at the Mission School, which is run by two foreigners, Olivia Weston and Father Juilliard. They learn more about José Angelico and Gabriel, a journalist serving a life sentence at Colva Prison. That night, police tear apart Raphael's shanty and bring him to the police station in town. They interrogate him violently, hitting him and dangling him out the window, threatening to drop him to his death. But Raphael sticks with his story, and they release him to run home to the dump covered in blood. Raphael explains to the reader that in their research online, the boys learned José was murdered by the police during an interrogation—perhaps in the same room Raphael just left. José stole six million US dollars from Senator Zapanta, the country's vice-president. He worked in the man's house as a houseboy for eight years before the theft. Raphael knows they have to deliver José's letter to Gabriel.
Olivia Weston narrates most of the middle part of the story, explaining that the boys fooled her into believing Gardo needed to visit his grandfather in prison because of a dispute with his house. She spends considerable sums of money getting Gardo new clothes and taking a taxi to the prison. They are charged ten thousand pesos just to see Gabriel, who says he doesn't know Gardo. In coded language, Gardo asks the political prisoner about certain lines in the letter he has memorized. Olivia sits oblivious to what has happened. Gabriel explains that he sought to prove Zapanta stole millions of dollars intended as an international donation to help the poor. Gabriel was framed for murder in retaliation. He realizes that José's message means the money has been taken. He tells Gardo the numbers correspond to his Bible, which is needed to decrypt the coded message. The guard, Marco, won't let Gardo take the Bible, but he assures Gabriel he will bring it to Behala. Meanwhile, Raphael and Rat visit Zapanta's mansion, hopping the fence. A gardener befriends them and explains how the houseboy made off with six million dollars by sneaking it out in a busted fridge. The old man laughs at the humiliation his employer is going through, adding that Zapanta has been stealing from the poor for decades.
Gardo's and Olivia's visit to the prison draws the attention of police, who question Olivia the next morning. She admits nothing and then takes a plane out of the country the same day. The boys escape, paying for a rented room in the town with money Rat has been saving to buy a boat. Rat cuts Raphael's hair and changes his clothes. Gardo goes to meet Marco outside the prison and learns he wants twenty thousand pesos for the Bible. Rat sneaks back to the Mission School, breaking in and stealing twenty-three thousand from the safe, whose combination he knows because he has made a habit of skimming some cash off the stack every month. Gardo takes the money to a teahouse in Chinatown. After trading it for the Bible, he senses danger and tries to run, but Marco grabs him. Gardo slashes the guard's face with a hook, then escapes out the door, passing a cop. He tosses the Bible to Rat, who goes a separate way. Both boys duck and dodge until no one is following them.
That night, the boys figure out how to decode the numbers using the Bible. It says: "Go to the map ref where we lay look for the brightest light my child." They realize other numbers correspond to a graveyard on the map. Later, they wake to the sound of police at their rented house. They escape through a hatch they've cut in the roof and run over rooftops, jumping into the window of an abandoned building full of street kids. Blending in with the others, the boys make it to the street while the swarm of police stands confused. They get into a taxi and head for the graveyard.
Because it is November 2, All Souls' Day, the graveyard is teeming with people who have come to pay their respects to dead relatives. The boys spend the day among rich people, searching for a clue. It is only at night that they realize they should be on the other side of the wall that divides the rich side from the poor side. There, they find the Angelico family's graves, which are not buried, but stacked in coffin-sized concrete compartments. These graves are rented for five years at a time. They contemplate breaking open José's wife's, son's, or daughter's graves, unsure whether he would hide money with a body. But when his daughter Pia Dante appears in the graveyard, saying she is waiting for her father, they realize that the money must be in the grave with her name on it. The boys give the malnourished girl food and rent her a room to rest. They break open her grave that night and find the six million dollars in a child's coffin.
The boys know they won't be able to keep the money long, so they put the last part of their plan into action, returning to Behala right away. They change into school uniforms Rat finds at the Mission School, stuffing new backpacks with money. Pre-typhoon winds are blowing in from the sea. They go to the top of Rat's old conveyor belt home and release fistfuls of money, letting five and half million dollars blow over Behala. They keep the rest and take a train south, catching a ferry that brings them to Sampalo, where Rat is from. On the island, they buy boats and learn how to fish. They end the story by saying they intend to keep fishing.
An appendix follows: it is the letter José left with the money. He explains how he gained the vice-president's trust over eight years before seizing an opportunity to sneak out the money from the man's vault. He asks the finder of the money to return it to the poor, to whom it belongs, and to take care of his daughter, Pia Dante.