The story is set in motion by a family hiking trip, during which Trisha's brother, Pete, and mother constantly squabble about the mother's divorce from their father, as well as other topics. Trisha falls back to avoid listening and is therefore unable to find her family again after she wanders off the trail to take a bathroom break. Trying to catch up by attempting a shortcut, she slips and falls down a steep embankment and ends up hopelessly lost, heading deeper into the heart of the forest. She is left with a bottle of water, two Twinkies, a boiled egg, a tuna sandwich, a bottle of Surge, a poncho, a Game Boy, and a Walkman. Now and then she listens to her Walkman to keep her mood up, either to learn of news of the search for her, or to listen to the baseball game featuring her favorite player, and "heartthrob," Tom Gordon.
As she starts to take steps to survive by conserving what little food she has with her and consuming edible flora, her mother and brother return to their car without her and call the police and start a search. The rescuers search in the area around the path, but not as far away as Trisha has gone. The girl decides to follow a creek because of what she read in Little House on the Prairie (though it soon turns into a swamp-like river), rationalizing that all bodies of water lead eventually to civilization.
As the cops stop searching for the night, she huddles up underneath a tree to rest. Eventually, a combination of fear, hunger, and thirst causes Trisha to hallucinate. She imagines several people from her life, as well as her hero, Tom Gordon, appearing to her. It is left unclear whether increasingly obvious signs of supernatural events in the woods are also hallucinations.
Hours and soon days begin to pass, with Trisha wandering further into the woods. Eventually she begins to believe that she is headed for a confrontation with the God of the Lost, a wasp-faced, evil entity who is hunting her down. Her trial becomes a test of a 9-year-old girl's ability to maintain sanity in the face of seemingly certain death. Racked with pneumonia and near death, she comes upon a road, but just as she discovers signs of civilization, she is confronted by a bear, which she interprets as the God of the Lost in disguise. Facing down her fear, she realizes it is the bottom of the ninth, and she must close the game. In imitation of Tom Gordon, she takes a pitcher's stance and throws her Walkman like a baseball, hitting the bear in the face, and startling it enough to make it back away. A hunter who has come upon the confrontation between girl and beast frightens the beast away and takes Trisha to safety, but Trisha knows that she earned her rescue.
Trisha wakes up in a hospital room. She finds her divorced parents and older brother waiting near her bedside. A nurse tells the girl's family that they must leave so that Trisha can rest because "her numbers are up and we don't want that." Her father is the last to leave. Before he does Trisha asks him to hand her a Red Sox hat (autographed by Tom Gordon) and she points towards the sky, just as Tom Gordon does when he closes a game.