Béla Balázs actually intended the poem for Zoltán Kodály, but Béla Bartók had already read it in 1910, the year it was written. It left an indelible impression on him; the symbolic text gave him the opportunity to bring together in music almost all the problems, crises and doubts of his life so far.
Brought about by his readings of Nietzsche, Bartók felt at the time that he was living in a kind of limbo, hovering over the earth, detached from everyday life, a state which was compacting into fatal loneliness.
He submitted his one-act work to the Budapest opera competition in 1911 […]; the jury […] rejected it, declaring it was unplayable. The composer reworked it in 1912 (probably on the advice of Zoltán Kodály), and then again several times after that; the definitive design of the close cost him much effort […]
The first performance took place seven years after the initial version was finished, and not before the successful premiere of his second work for the stage, The Wooden Prince, in 1917.
The source of Balázs’ text, the Bluebeard legend, had existed in differing versions since the last decade of the 17th century in the European literature. Balázs himself called his poem a Mystery, declaring in the prologue that the scene of the events was the human soul; instead of a prologue, Bartók composed a four-part orchestral prelude reminiscent of a Hungarian folk song, to introduce the ballad-like atmosphere and to close the framework in the opera’s final bars. Within that frame, the work consists of a prelude and seven scenes; the symbolical setting, Duke Bluebeard’s castle, is actually the male soul, while the castle’s seven doors each correspond to a part of the psyche, a male particularity, a part of male life. The characters are likewise symbolic, the duke being Man and Judith Woman per se.
From © György Kroó, Bartók-Handbuch, Universal Edition, Vienna, 1974