The family trips were often challenging, and travel conditions were primitive. They had to wait for invitations and reimbursement from the nobility, and they endured long, near-fatal illnesses far from home: first Leopold (London, summer 1764), then both children (The Hague, autumn 1765). The family again went to Vienna in late 1767 and remained there until December 1768. After one year in Salzburg, Leopold and Wolfgang set off for Italy, leaving Anna Maria and Nannerl at home. This tour lasted from December 1769 to March 1771. As with earlier journeys, Leopold wanted to display his son's abilities as a performer and a rapidly maturing composer. Wolfgang met Josef Mysliveček and Giovanni Battista Martini in Bologna and was accepted as a member of the famous Accademia Filarmonica. In Rome, he heard Gregorio Allegri's Miserere twice in performance, in the Sistine Chapel, and wrote it out from memory, thus producing the first unauthorized copy of this closely guarded property of the Vatican. In Milan, Mozart wrote the opera Mitridate, re di Ponto (1770), which was performed with success. This led to further opera commissions. He returned with his father twice to Milan (August–December 1771; October 1772 – March 1773) for the composition and premieres of Ascanio in Alba (1771) and Lucio Silla (1772). Leopold hoped these visits would result in a professional appointment for his son, and indeed ruling Archduke Ferdinand contemplated hiring Mozart, but owing to his mother Empress Maria Theresa's reluctance to employ "useless people", the matter was dropped[n 4] and Leopold's hopes were never realized. Toward the end of the journey, Mozart wrote the solo motet Exsultate, jubilate, K. 165.Mozart did indeed soon meet the Emperor, who eventually was to support his career substantially with commissions and a part-time position. In the same letter to his father just quoted, Mozart outlined his plans to participate as a soloist in the concerts of the Tonkünstler-Societät, a prominent benefit concert series; this plan as well came to pass after the local nobility prevailed on Colloredo to drop his opposition. Colloredo's wish to prevent Mozart from performing outside his establishment was in other cases carried through, raising the composer's anger; one example was a chance to perform before the Emperor at Countess Thun's for a fee equal to half of his yearly Salzburg salary. The quarrel with the archbishop came to a head in May: Mozart attempted to resign and was refused. The following month, permission was granted, but in a grossly insulting way: the composer was dismissed literally "with a kick in the arse", administered by the archbishop's steward, Count Arco. Mozart decided to settle in Vienna as a freelance performer and composer. The quarrel with Colloredo was more difficult for Mozart because his father sided against him. Hoping fervently that he would obediently follow Colloredo back to Salzburg, Mozart's father exchanged intense letters with his son, urging him to be reconciled with their employer. Mozart passionately defended his intention to pursue an independent career in Vienna. The debate ended when Mozart was dismissed by the archbishop, freeing himself both of his employer and of his father's demands to return. Solomon characterizes Mozart's resignation as a "revolutionary step" that significantly altered the course of his life.In 1782 and 1783, Mozart became intimately acquainted with the work of Johann Sebastian Bach and George Frideric Handel as a result of the influence of Gottfried van Swieten, who owned many manuscripts of the Baroque masters. Mozart's study of these scores inspired compositions in Baroque style and later influenced his musical language, for example in fugal passages in Die Zauberflöte ("The Magic Flute") and the finale of Symphony No. 41. In 1783, Mozart and his wife visited his family in Salzburg. His father and sister were cordially polite to Constanze, but the visit prompted the composition of one of Mozart's great liturgical pieces, the Mass in C minor. Though not completed, it was premiered in Salzburg, with Constanze singing a solo part. Mozart met Joseph Haydn in Vienna around 1784, and the two composers became friends. When Haydn visited Vienna, they sometimes played together in an impromptu string quartet. Mozart's six quartets dedicated to Haydn (K. 387, K. 421, K. 428, K. 458, K. 464, and K. 465) date from the period 1782 to 1785, and are judged to be a response to Haydn's Opus 33 set from 1781. Haydn wrote, "posterity will not see such a talent again in 100 years" and in 1785 told Mozart's father: "I tell you before God, and as an honest man, your son is the greatest composer known to me by person and repute, he has taste and what is more the greatest skill in composition." From 1782 to 1785 Mozart mounted concerts with himself as a soloist, presenting three or four new piano concertos in each season. Since space in the theatres was scarce, he booked unconventional venues: a large room in the Trattnerhof apartment building, and the ballroom of the Mehlgrube restaurant. The concerts were very popular, and his concertos premiered there are still firm fixtures in his repertoire. Solomon writes that during this period, Mozart created "a harmonious connection between an eager composer-performer and a delighted audience, which was given the opportunity of witnessing the transformation and perfection of a major musical genre". With substantial returns from his concerts and elsewhere, Mozart and his wife adopted a more luxurious lifestyle. They moved to an expensive apartment, with a yearly rent of 460 florins. Mozart bought a fine fortepiano from Anton Walter for about 900 florins, and a billiard table for about 300. The Mozarts sent their son Karl Thomas to an expensive boarding school and kept servants. During this period Mozart saved little of his income. On 14 December 1784, Mozart became a Freemason, admitted to the lodge Zur Wohltätigkeit ("Beneficence"). Freemasonry played an essential role in the remainder of Mozart's life: he attended meetings, a number of his friends were Masons, and on various occasions, he composed Masonic music, e.g. the Maurerische Trauermusik.
Despite the great success of Die Entführung aus dem Serail, Mozart did little operatic writing for the next four years, producing only two unfinished works and the one-act Der Schauspieldirektor. He focused instead on his career as a piano soloist and writer of concertos. Around the end of 1785, Mozart moved away from keyboard writing[page needed] and began his famous operatic collaboration with the librettist Lorenzo Da Ponte. The year 1786 saw the successful premiere of The Marriage of Figaro in Vienna. Its reception in Prague later in the year was even warmer, and this led to a second collaboration with Da Ponte: the opera Don Giovanni, which premiered in October 1787 to acclaim in Prague, but less success in Vienna during 1788. The two are among Mozart's most famous works and are mainstays of operatic repertoire today, though at their premieres their musical complexity caused difficulty both for listeners and for performers. These developments were not witnessed by Mozart's father, who had died on 28 May 1787.