Whatever the opposite of a social butterfly is, Greg Gaines is that; a senior at Benson High School, he survives by becoming acquaintances with everybody, and friends with nobody. He avoids becoming a member of a social clique yet remains on friendly terms with all of them. He has an actual real friend, called Earl, but he doesn't really publicly claim the friendship. He tentatively terms them "co-workers". The real story is that they have been friends since they were very young children; Earl is from a poor area, and he comes from a broken home. Greg and Earl spend most of their time together, making short films, but they never tell anyone; high school is a cruel and difficult place sometimes, and they are sure that if they share their films with their peers they will be ridiculed.
A few years earlier, Greg had employed the classic shady move designed to get him closer to the girl he was interested in; he made friends with her best friend. He befriended Rachel because he wanted to get to know her friend Leah, who was the prettiest girl he had ever seen. Now, his mother tells him, Rachel is very sick, having been diagnosed with acute myelogenous leukemia, which is a fast-moving disease. Greg's mom wants him to re-connect with Rachel, because she thinks it will lift Rachel's spirits a little. Greg doesn't really want to re-connect, but he can't tell his mother because then he will have to admit why he had made friends with Rachel in the first place, so he calls her. The call is awkward and Greg doesn't want to pursue the friendship, but his mother forces him to. Eventually, the two start to spend more time together again.
Greg and Earl accidentally get high whilst they are at school, which is horrible timing because Rachel texts Greg that day to tell him that she is starting chemotherapy the following day. Despite their condition the two drive to Rachel's house; Rachel hasn't met Earl yet, although she's heard a lot about him. The three go out for ice cream and Earl and Rachel get along so well that Earl asks her if she would like to watch one of their films. This makes Greg angry, but he doesn't say anything. He preferred it when the film making was a secret.
School isn't going so well for Greg. He is falling behind and in danger of failing all of his classes. Despite this his parents want him to apply for college and start to pressure him heavily to do so. Rachel thinks he should pursue film school. Rachel has also let it slip to a couple of her friends that Earl and Greg make films; Madison Hartner, who has been Greg's secret crush for years, asks him to make a movie for Rachel. They work hard on it; they combine all of their ideas in one movie entitled Rachel The Film, and intend to give it to Rachel, but it is shown to the entire school during a special assembly. He is absolutely mortified and stops going to school at all. He also destroys all of his old films. He is emotionally scarred by the entire experience.
Rachel passes away just a few days after her film is screened. The strange thing is, when Greg goes to Earl's house to talk about her passing, he finds that Earl, too, has destroyed all of their films. Neither one has the stomach for their old work now Rachel has gone. Greg tells Earl that he is going to apply to film school, but Earl thinks this is a terrible idea, because he thinks losing Rachel should not influence his future plans.
So why did Greg write this book? Well, he tells us in the epilogue; it was his college essay in elongated form. He needed to explain to his college of choice, Pittsburgh, why his grades dropped the previous year; he took Earl's opinions to heart, and abandoned his plans to study film. The thing is, though, writing down what he has been through and reliving it all over again made him realize that he really did want to go to film school, and that he had been trying to be someone other than himself his entire life. Film school was what he truly wanted. He decides to apply again, and to learn to be happy being himself.