The History Boys is set at a boys’ secondary school in Northern England in the 1980s. It focuses on a group of 8 sixth-form boys and their teachers as they prepare to take their entrance exams for admission into Oxford or Cambridge.
Hector, a veteran teacher in his 60s, is ambivalent about the course in General Studies to which he has been assigned. He also disapproves of the boys’ common goal to earn a spot in either Oxford or Cambridge. In the staff room, Mr. Felix Armstrong (the school's Headmaster) and Mrs. Lintott, the history teacher, discuss the "Oxbridge boys" - they have never had so many students with such excellent A-Level scores before. The Headmaster commends Mrs. Lintott for teaching the boys so well, but he believes that they lack the necessary polish for admittance into the top-tier schools. Besides Rudge, the Headmaster thinks that the boys have potential.
Outside, Irwin (aged 25) enters the school. Irwin's only role is to prepare the boys for their Oxbridge entrance examinations and interviews. The Headmaster interrupts Hector's lesson to inform him about the new teaching arrangement with Irwin; Hector is furious. At the end of the class period, Scripps agrees to go on a motorcycle ride with Hector. After Scripps and Hector leave, the remaining boys discuss Hector’s mysterious process of selecting boys for motorcycle rides.
As he begins his new duties, Irwin tells the boys that they will need to impress the Oxbridge examiners rather than just regurgitate facts. In an aside, Posner tells the audience that Irwin’s unconventional approach to history will one day lead him to a career as a well-known historical journalist.
Later, Mrs. Lintott asks Irwin about his interactions with the students. Irwin tells Mrs. Lintott that Posner has confessed his homosexuality to him, specifically to ask Irwin for advice about his unrequited love for Dakin. Irwin's conversations with Mrs. Lintott and Posner take place simultaneously; Irwin skirts the question of his own sexuality in both interactions. Meanwhile, it is clear that Dakin is developing romantic feelings for Irwin, even though he has told Posner that he likes girls.
Hector and Irwin discuss the boys' level of preparation for the Oxbridge exam. Irwin feels that the boys consider the information they learn in Hector's class to be off-limits for the exams. Hector reiterates that he sees such entrance exams as the enemy of education. Irwin accepts that taking examinations is a fact of life and asks Hector what is value of the knowledge he is teaching the boys if it will not help them get into Oxbridge. Hector replies that what the boys learn in his class will serve them later in their lives, which will continue regardless of their exam results.
The Headmaster checks in on Irwin's progress. Though Irwin believes that the boys are progressing, he hesitates to guarantee that any one of them will get into Oxford or Cambridge. This perturbs the Headmaster, who goes on to criticize Hector’s teaching methods because they do not produce any quantifiable results. Mrs. Lintott privately shares with Irwin her opinion that the Headmaster is the chief enemy of culture in any school.
The next scene begins with an aside from Scripps. He informs the audience that it is halfway through the term; Hector has been summoned to the Headmaster’s office. In their meeting, the Headmaster reveals to Hector that his wife saw Hector molesting one of his students while taking him for a ride on his motorbike. Hector responds calmly to the accusation and tries to defend himself. The Headmaster, however, is unconvinced and demands Hector’s resignation.
Ignorant to Hector's dismissal, Dakin asks Hector he can take a ride with Hector on his motorbike after their lesson, but Hector declines.
Several years in the future, Irwin, who is in a wheelchair, is narrating a historical television program. A man, who turns out to be Posner, approaches Irwin and tries to find out if anything happened between him and Dakin all those years ago; he is writing a newspaper story about the incident and needs a quote. Irwin becomes angry at Posner, refuses to give him any information, and wheels himself away.
The next scene goes back in time to Hector's classroom. After announcing that he and Irwin will be sharing lessons for the remainder of the term, Hector starts crying. Posner awkwardly rubs his teacher's back.
When Hector and Irwin teach their first joint lesson, the topic of discussion is World War II. Irwin tries to teach the boys new ways of looking at the Holocaust, but Hector questions how they can analyze the historical significance of the Holocaust without demeaning the victims' suffering. As rumors about Hector's impending departure circulate, the Headmaster confronts Irwin about a letter of complaint he has received from Posner's parents about the manner in which Irwin speaks about the Holocaust. Irwin tries to defend his methods, but the Headmaster commands him to write a letter of apology.
As the term comes to a close, each of the teachers has a private meeting with the Headmaster. Hector already knows that he will not be returning. Mrs. Lintott informs the Headmaster that she is going to retire, as well, and projects that the Headmaster will invite Irwin to take her place. However, after her private meeting with the Headmaster, Mrs. Lintott tells Hector that the Headmaster is going to ask Hector to take her place as the history teacher instead of Irwin.
The boys describe their experiences taking their exams. All of them, including Rudge, earn spots at Oxbridge.
After returning from Cambridge, Dakin confronts Irwin and forces him to admit that he lied about attending Corpus Christi College as an undergraduate. Instead of criticizing Irwin for his deception, Dakin instead propositions his teacher. Irwin is hesitant, but Dakin eventually convinces him to "get a drink" the following Sunday. In the next scene, Dakin reveals to his classmates that he has blackmailed the Headmaster into letting Hector stay. Hector is jubilant about being reinstated; Dakin wants to go on a motorcycle ride with Hector as a "reward" for his longtime teacher. The Headmaster, however, is understandably horrified to see Dakin wearing Hector’s motorcycle helmet, as it violates his agreement with Hector. The Headmaster suggests that Hector take Irwin on his bike instead, and Irwin agrees.
Scripps then informs the audience that the Hector's bike crashed, killing Hector and leaving Irwin paralyzed from the waist down. The final scene of The History Boys takes place at Hector's funeral. The Headmaster and the boys eulogize the fallen educator, speaking about his love of literature. Mrs. Lintott reveals the fate of each of Hector's students, almost all of whom become successful professionals.