Tris and Four inject Jeanine with the mind-control serum and make her call off the simulation, preventing Dauntless from executing Abnegation. The two of them, Caleb, and Marcus then flee the city.
In a dystopian future, Chicago is a city divided into five factions to maintain order following a great war. Erudite are the smartest and most logical thinkers, and dress in blue. Amity are kind and peaceful, and dress in orange and yellow. Candor are honest, and dress in black and white. Dauntless are brave and exhibit crazy behavior, and dress in all black. Abnegation are selfless and do not value power or vanity, and dress in grey. Abnegation also runs the government. There is another group, the Factionless, who have no place in this society and are homeless. When a child reaches the age of 16, they must choose which faction they will be a part of. They are tested to see which faction they are best suited for, then they make their decision official at the Choosing Ceremony. The child is not bound to choose the faction they tested best for, nor the one they grew up in, but once they choose, the decision is final and they can never return to the faction they grew up in if they transferred to another one.
Andrew Prior (Tony Goldwyn) is on the ruling council, and is married to Natalie (Ashley Judd). Their twin children, Beatrice (Shailene Woodley) and Caleb, take the faction test. Beatrice discovers that she showed traits of multiple factions, and those people are called Divergent. She is told by her test proctor not to tell anyone this, because Divergents can think independently and cannot be controlled, so they are considered threats to the new world order. At the Choosing Ceremony, Caleb chooses Erudite and Beatrice, after some hesitation, chooses Dauntless. After the ceremony, Beatrice befriends another transfer to Dauntless, Christina (Zoe Kravitz), as well as two others, Al and Will. On their first day of training, the group of initiates meets their training leader, Eric (Jai Courtney), who tells them that if they fail to meet his extremely high rate of expectations, they will be expelled from Dauntless and forced to join the Factionless for the rest of their lives. They also meet Max (Mekhi Phifer), the head of the Dauntless faction. Beatrice is assigned to the transfer initiates team, led by Four (Theo James), and it's here that she chooses to begin her new life by shortening her name to Tris.
Tris struggles at her training, and finds herself below the cutoff after the first evaluation. Because she is constantly picked on by the others, she uses that as motivation and quickly improves. A bad beating in a training fight lands Tris in the hospital, but she leaves when she learns she will be cut if she misses that night's test. She joins the initiates, and leads her team to victory over the born-Dauntless initiates team, securing her place in the next round of training. The next round is psychological training, and Four tells her she will enter into her own mind to face her fears, and how she beats them will determine whether or not she advances to the final round. She passes her tests in unique ways, but Four warns her not to do that in the final, because that uniqueness will expose her as a Divergent. He tells her to beat the test as a normal Dauntless. Later, Tris meets her brother, who tells her that Erudite, especially their leader Jeanine (Kate Winslet), is not happy with the way Abnegation is running the government, and they are planning a coup. When she returns to the Dauntless headquarters, she is attacked by Al and two others, nearly killing her, before Four comes to her rescue. She spends the night in his room, and they begin to show feelings for each other. The next day, Al apologizes to Tris, but she refuses to accept it, calling him a coward. Al then commits suicide rather than face being a failure.
As a preparation for the final test, Four takes Tris into his mind and will face his fears. She learns that his real name is Tobias, he has four real fears (thus the nickname Four), and one of them is of his father, Marcus Eaton, the head of Abnegation, who used to beat him. It's here that Tris and Four kiss for the first time. Tris takes the final the next day, and takes Four's advice to solve the tests as a Dauntless. She easily passes, and is now officially a member of Dauntless. Since Dauntless are the city's protection force, they are told they need to be injected with a tracker in case they are in trouble. However, the tracker is actually a mind-control serum developed by Erudite, and they plan on using Dauntless as part of their coup. The next day, all of Dauntless enter the Abnegation part of town and round up everyone, thinking it's part of a simulation. They are also ordered to shoot-to-kill any Divergents they find. Since Divergents are not affected by the serum, Tris plays along until she can get away to save her parents. She sees Four is also not affected, which reveals him to be a Divergent as well. Together, they split off from the rest and look for her parents, but they already escaped. Eric and Max both see that Tris and Four are not affected and quickly capture them. Four is taken away and Tris is to be executed, but she is saved by her mother Natalie, and they flee into the city.
During their escape, Tris is forced to kill several Dauntless in a shootout, including her former classmate Will, but Natalie is also shot and killed. Tris continues on to the safehouse, where she sees her father Andrew, Caleb, Marcus, and others who are in hiding. Caleb left Erudite before the coup began and got his family and others away in time. By this time, Tris has figured out that the Erudite control center is in the Dauntless headquarters, so she, Caleb, Andrew, and Marcus go there. Inside, there is another shootout, and all of the guards are killed, but so is Andrew. Tris goes into the control room, but is quickly captured. She sees Four, who was given a stronger dose of the serum, and he is ordered by Jeanine to kill Tris. He attacks her, but Tris uses her knowledge of his fears to get him to snap out of it and they go after Jeanine. She is about to order Dauntless to execute all of Abnegation, but Tris and Four give her an injection of the mind-control serum and order her to call off the simulation, which she does. With Dauntless waking up and wondering what is happening, Tris knocks out Jeanine and she and Four leave the control room. As the movie ends, Four reunites with his father (and is not happy about it), and they, Tris, and Caleb board a train heading out of the city, setting up the events for the sequel, Insurgent.