For the last seven years of his life Wolfgang Amadeus Mozart was a Mason. The Masonic order played an important role in his life and work.
Mozart was admitted as an Apprentice to the Viennese Masonic lodge called "Zur Wohltätigkeit" ("Beneficence") on 14 December 1784. He was promoted to Fellow on 7 January 1785, and became a Master Mason "shortly thereafter". Mozart also attended the meetings of another lodge, called "Zur wahren Eintracht" ("True Concord"). According to Otto Erich Deutsch, this lodge was "the largest and most aristocratic in Vienna. ... Mozart, as the best of the musical 'Brothers,' was welcome in all the lodges." It was headed by the naturalist Ignaz von Born.
Mozart's own lodge "Zur Wohltätigkeit" was consolidated with two others in December 1785, under the Imperial reform of Masonry (the Freimaurerpatent, "Masonic Decree") of 11 December 1785, and thus Mozart came to belong to the lodge called "Zur Neugekrönten Hoffnung" (New Crowned Hope).
At least as far as surviving Masonic documents can tell us, Mozart was well regarded by his fellow Masons. Many of his friends were Masons.
During his visit to Vienna in 1785, Mozart's father Leopold also became a Mason.
Mozart's position within the Masonic movement, according to Maynard Solomon, lay with the rationalist, Enlightenment-inspired membership, as opposed to those members oriented toward mysticism and the occult. This rationalist faction is identified by Katharine Thomson as the Illuminati, a masonically inspired group which was founded by Bavarian professor of canon law Adam Weishaupt, who was also a friend of Mozart. The Illuminati and rationalist Masons espoused the Enlightenment-inspired, humanist views proposed by the French philosophers Jean-Jacques Rousseau and Denis Diderot. For example, they contended that social rank was not coincident with nobility of the spirit, but that people of lowly class could be noble in spirit just as nobly born could be mean-spirited. This view appears in Mozart's operas; for example, in The Marriage of Figaro, an opera based on a play by Pierre Beaumarchais (another Freemason), the low-born Figaro is the hero and the Count Almaviva is the boor.
The Freemasons used music in their ceremonies (see Masonic music), and adopted Rousseau's humanist views on the meaning of music. "The purpose of music in the [Masonic] ceremonies is to spread good thoughts and unity among the members" so that they may be "united in the idea of innocence and joy," wrote L.F. Lenz in a contemporary edition of Masonic songs. Music should "inculcate feelings of humanity, wisdom and patience, virtue and honesty, loyalty to friends, and finally an understanding of freedom."
These views suggest a musical style quite unlike the style of the Galant, which was dominant at the time. Galant style music was typically melodic with harmonic accompaniment, rather than polyphonic; and the melodic line was often richly ornamented with trills, runs and other virtuosic effects. The style promoted by the Masonic view was much less virtuosic and unornamented. Mozart's style of composition is often referred to as "humanist" and is in accord with this Masonic view of music.
The music of the Freemasons contained musical phrases and forms that held specific semiotic meanings. For example, the Masonic initiation ceremony began with the candidate knocking three times at the door to ask admittance. This is expressed musically as a dotted figure:
This figure appears in Mozart's opera The Magic Flute in the overture, suggesting the opening of the Masonic Master Mason's degree.  According to Katherine Thomson, there are many other examples of specific musical symbols taken from the Masonic rites that appear throughout Mozart's compositions. These include the use of suspensions to indicate friendship and brotherhood, the use of three-part harmony to emphasize the special significance of the number three in Freemasonry, and special rhythms and harmonies to signify fortitude and other attributes.
Notwithstanding these manifestations of Freemasonry in Mozart's music and activities, some scholars question Mozart's personal commitment to Masonic ideology. Peter Paul Fuchs notes that Mozart was a devout Catholic, a religion that threatened Freemasons with excommunication. "Mozart was pulled in various directions stylistically and probably personally. There is little evidence that he found these tensions troubling... " he writes. However in his book Mozart and the Enlightenment Nicholas Till demonstrates that Mozart's original lodge "Zur Wohltätigkeit" (At Beneficence) was a reform-Catholic lodge following the tenets of the Italian liberal theologian Ludovico Muratori and was committed in particular to the Catholic ideal of charity. And musicologist David J. Buch notes that many of Mozart's musical devices identified with Masonry have precedents in non-Masonic music as well.  For example, the three notes, which originate from the French genre of "le merveilleux", already appear in the musical theater of the early 18th century. The three chords in the overture can be found in many other 18th-century stage works, such as Traetta's Armida and Gazzaniga's La Circe, operas that have no connection with Freemasonry.
The following is a list of surviving works that Mozart composed for performance at gatherings of Masons.
The story and music of his opera The Magic Flute is also considered to have strong Masonic influences.
The following is a partial list of family members, patrons, and colleagues who were Masons.
Mozart's grandfather Johann Georg, a bookbinder, was raised among the extended Mozart family in Augsburg, in the house of Johann's own grandfather David Mozart. David and his children were distinguished architects and master operative (craft) masons of the Augsburg guild (as contrasted to speculative freemasons). But close affinities among operative and speculative existed in this period.