Set in the mid-16th century Nuremberg
The first act unfolds in St Catherine's Church, where a mass is concluding. Among the congregants is Eva, the daughter of the wealthy jeweler Veit Pogner, accompanied by her nanny, Magdalene. The young knight Walther von Stolzing, smitten with Eva, confesses his feelings to her. Eva reciprocates his affection but reveals that according to her father's will only the winner of the Meistersinger (masters of song) competition, scheduled for the next day's St John's Day celebrations, can win her hand in marriage. Eager to compete, Walther, unfamiliar with the customs and traditions of the Meistersingers, finds himself at a loss. David, Magdalene's admirer and apprentice to one of the most respected singers, the cobbler Hans Sachs, attempts to elucidate the intricate rules of composing verses and music to the knight. Meanwhile, the Meistersingers, all artisans of the town, gather in the church. Among them are Eva's father, Sachs, and the town clerk Sixtus Beckmesser, who also aspires to marry Eva. Pogner reminds everyone of his decision: Eva is to marry the victor of the Meistersinger contest, or if she rejects him, remain unmarried. The Meistersingers endorse this decision but reject Sachs's proposal to entrust the selection of the winner to the people. Walther, unknown to the master singers but advocated for by Pogner, requests to join their guild. He is given a trial: to become a Meistersinger he must perform a song. His performance, though heartfelt and impassioned, fails to comply with the established norms and fails to win favor. Beckmesser, with malicious glee chalks up Walther's errors on a board, one after another. Only Sachs appreciates Walther's rendition but cannot sway the opinion of the other masters – Walther is denied entry.
The second act takes place late in the evening and throughout the night preceding the festival. The houses of Pogner and Sachs are situated side by side. Magdalene learns from David about Walther's failure and shares this news with Eva. Sachs, engaged in his usual work, reminisces about Walther's stirring song. When Eva visits him, he informs her that Beckmesser intends to win the next day's competition. Eva, discontented with this outcome and doubtful of Walther's victory, admits she wouldn't mind if Sachs himself were to win. Knowing Eva since her childhood, Sachs feels only paternal love for her and feigns criticism of Walther to reveal her true feelings for the knight. Walther soon appears and suggests that Eva run away with him, for which she would need to switch clothes with Magdalene. Overhearing their conversation, Sachs decides to foil their plan while simultaneously aiding the lovers.
Beckmesser arrives at Pogner's house, intending to serenade Eva under her window, unaware that Magdalene has taken her place. Sachs, still awake and working, sings himself, and when Beckmesser begins his serenade, Sachs loudly hammers on a sole every time Beckmesser makes a mistake. Suddenly, David attacks Beckmesser, mistakenly thinking that the clerk is courting Magdalene. The noise awakens other residents of the street, and a brawl ensues. Sachs thwarts Eva and Walther's attempt to flee amidst the chaos, and the night watchman, blowing his horn, interrupts the scuffle.
On the festive morning David seeks forgiveness for his involvement in the night's brawl and wishes his teacher, Sachs, a happy birthday. Alone, Sachs reflects on the prevailing madness in the world. Walther, who spent the night at Sachs's home, recounts a wondrous dream he had. Sachs suggests turning this dream into a song and encourages the knight, helping him arrange the verses and transcribing the text. When Walther leaves to dress in his festive attire, Beckmesser arrives to collect his shoes. Spotting the freshly written song and assuming Sachs to be the author, Beckmesser attempts to steal it. Sachs catches him and, claiming not to be competing, generously hands over the song but warns Beckmesser of its complexity. Shortly after, Eva arrives to have her shoes repaired. Witnessing his beloved, an inspired Walther sings his song anew, now even more refined. Torn between her feelings for Walther and her affection for Sachs, Eva ultimately sees Sachs gracefully concede to the younger knight and bless his performance. Sachs informs David that he is now a journeyman, eligible to marry Magdalene.
The festival takes place on the banks of the Pegnitz River, attended by all the craft guilds. Sachs's arrival sparks universal admiration. Beckmesser sings first but bungles the song mixing up the words comically, earning only ridicule. He accuses Sachs of deliberately giving him a flawed text and storms off in anger. Sachs then invites the audience to hear Walther. The knight's hymn in praise of love unanimously wins him the contest and the mastersingers are ready to welcome him into their guild. Walther initially refuses, content with winning Eva's heart. However, Sachs convinces him to accept the accolade and uphold the duty of a master to preserve the grand German art and spirit. The crowd once again lauds Sachs as Nuremberg's treasure.