Sam Dawson (Sean Penn), a man with an intellectual disability, is the single father of Lucy (Dakota Fanning) following their abandonment by her mother, a homeless woman. Sam is well-adjusted and has a supportive group of friends with disabilities, as well as a kind, agoraphobic neighbor, Annie (Dianne Wiest), who takes care of Lucy when Sam cannot. Though Sam provides a loving place for precocious Lucy, she soon surpasses his mental ability.
Other children bully her for having an intellectually disabled father, and she becomes too embarrassed to accept that she is more advanced than he is. In danger of losing custody, Sam gets advice from his friends and also hires a lawyer, Rita Harrison (Michelle Pfeiffer), whose absorption in her work and neglect of her son reveal her to be at least as handicapped as Sam is, although in a socially acceptable way. In an attempt to prove that she is not cold, Rita agrees to take on Sam’s case pro bono. As they work to secure Sam’s rights, Sam helps Rita see her own life anew. This includes encouraging her to leave her philandering husband and repair her fractious relationship with her son.
At the trial, Sam cries. Afterwards, Lucy resides in a foster home with Randy Carpenter (Laura Dern) but tries to convince Sam to help her run away. She continually escapes in the middle of the night to go to his apartment, though he immediately returns her. However, the foster parents decide not to adopt her as they had planned and return her to Sam. Randy assures him that she will tell the judge (Ken Jenkins) Sam is the better parent for Lucy. In turn, Sam asks Randy if she will help him raise Lucy, because he feels she needs a mother figure.
The final scene depicts a soccer game, in which Sam referees and Lucy participates as a player. In attendance are Lucy’s former foster family, Sam’s friendship group, and a newly single Rita with her son.