He was soon generally recognized as one of the most skillful organists of his time. The success of his comic opera, Il Filosofo convinto in amore, performed at Potsdam in 1750, led to an appointment as court composer to Frederick the Great. In 1759, on the death of Karl Heinrich Graun, he was appointed conductor of the royal orchestra. He married the noted operatic soprano Benedetta Emilia Molteni, a marriage of which the king apparently disapproved. Agricola died in Berlin at 54.
During his lifetime, Agricola wrote a number of Italian operas, as well as Lieder, chorale preludes, various other keyboard pieces and church music, especially oratorios and cantatas. His reputation chiefly rests, however, on his theoretical and critical writings on musical subjects. In 1754 he co-wrote with Carl Philipp Emanuel Bach an obituary for Bach-the-elder, Johann Sebastian Bach. His 1757 Anleitung zur Singekunst (Introduction to the Art of Singing) is Pier Francesco Tosi's 1723 treatise Opinioni de' cantori antichi e moderni with Agricola's own extensive comments.