In 1930s Edinburgh, six ten-year-old girls, Sandy, Rose, Mary, Jenny, Monica, and Eunice are assigned Miss Jean Brodie, who describes herself as being "in my prime," as their teacher. Miss Brodie, determined that they shall receive an education in the original sense of the Latin verb educere, "to lead out," gives her students lessons about her personal love life and travels, promoting art history, classical studies, and fascism. Under her mentorship, these six girls whom Brodie singles out as the elite group among her students—known as the "Brodie set"—begin to stand out from the rest of the school. However, in one of the novel's typical flash-forwards we learn that one of them will later betray Brodie, ruining her teaching career, but that she will never learn which.
In the Junior School, they meet the singing teacher, the short Mr Gordon Lowther, and the art master, the handsome, one-armed war veteran Mr Teddy Lloyd, a married Roman Catholic with six children. These two teachers form a love triangle with Miss Brodie, each loving her, while she loves only Mr Lloyd. However, Miss Brodie never overtly acts on her love for Mr Lloyd, except once to exchange a kiss with him, witnessed by Monica. During a two-week absence from school, Miss Brodie embarks on an affair with Mr Lowther on the grounds that a bachelor makes a more respectable paramour: she has renounced Mr Lloyd as he is married. At one point during these two years in the Junior School, Jenny is "accosted by a man joyfully exposing himself beside the Water of Leith." The police investigation of the exposure leads Sandy to imagine herself as part of a fictional police force seeking incriminating evidence in respect of Brodie and Mr Lowther.
Once the girls are promoted to the Senior School (around age twelve) though now dispersed, they hold on to their identity as the Brodie set. Miss Brodie keeps in touch with them after school hours by inviting them to her home as she did when they were her pupils. All the while, the headmistress Miss Mackay tries to break them up and compile information gleaned from them into sufficient cause for Brodie's dismissal. Miss Mackay has more than once suggested to Miss Brodie that she should seek employment at a 'progressive' school; Miss Brodie declines to move to what she describes as a 'crank' school. When two other teachers at the school, the Kerr sisters, take part-time employment as Mr Lowther's housekeepers, Miss Brodie tries to take over their duties. She sets about fattening him up with extravagant cooking. The girls, now thirteen, visit Miss Brodie in pairs at Mr Lowther's house, where all Brodie does is ask about Mr Lloyd in Mr Lowther's presence. At this point Mr Lloyd asks Rose and occasionally the other girls to pose for him as portrait subjects. Each face he paints ultimately resembles Miss Brodie, as her girls report to her in detail, and she thrills at the telling. One day when Sandy is visiting Mr Lloyd, he kisses her.
Before the Brodie set turns sixteen, Miss Brodie tests her girls to discover which of them she can really trust, ultimately settling on Sandy as her confidante. Miss Brodie is obsessed with the notion that Rose, as the most beautiful of the Brodie set, should have an affair with Mr Lloyd in her place. She begins to neglect Mr Lowther, who ends up marrying Miss Lockhart, the science teacher. Another student, Joyce Emily, steps briefly into the picture, trying unsuccessfully to join the Brodie set. Miss Brodie takes her under her wing separately, encouraging her to run away to fight in the Spanish Civil War on the Nationalist side, which she does, only to be killed in an accident when the train she is travelling in is attacked.
The original Brodie set, now seventeen and in their final year of school, begin to go their separate ways. Mary and Jenny leave before taking their exams, Mary to become a typist and Jenny to pursue a career in acting. Eunice becomes a nurse and Monica a scientist. Rose lands a handsome husband. Sandy, with a keen interest in psychology, is fascinated by Mr Lloyd's stubborn love, his painter's mind, and his religion. Sandy and Rose model for Mr Lloyd's paintings, Sandy knowing that Miss Brodie expects Rose to become sexually involved with Lloyd. Rose, however, is oblivious to the plan crafted for her and so it is Sandy, now eighteen and alone with Mr Lloyd in his house while his wife and children are on holiday, who has exactly such an affair with him for five weeks during the summer. Over time, Sandy's interest in the man wanes while her interest in the mind that loves Jean Brodie grows. In the end, Sandy leaves him, adopts his Roman Catholic religion, and becomes a nun. Beforehand, however, she meets with Miss Mackay and blatantly confesses to wanting to bring a stop to Miss Brodie. She suggests that the headmistress could accuse Brodie of encouraging fascism, and this tactic succeeds. Not until her dying moment a year after the end of World War II is Miss Brodie able to imagine that it was her confidante, Sandy, who betrayed her. After her death however, Sandy, now called Sister Helena of the Transfiguration and author of The Transfiguration of the Commonplace, maintains that "it's only possible to betray where loyalty is due." One day, an enquiring young man visits Sandy at the convent, because of her strange book on psychology. He enquires about the main influences of her school years, asking her: "Were they literary or political or personal? Was it Calvinism?" Sandy answers him, instead, by saying: "There was a Miss Jean Brodie in her prime."