Hofmann was the son of a highly educated civil servant, and at the age of seven became a chorister in the chapel of the Empress Elisabeth Christine, where his choral director and teacher was very likely František Tůma.
He was also a student later on of Georg Christoph Wagenseil and Giuseppe Trani (violin).
The position of Kapellmeister at the Cathedral of St. Stephan, a post he acquired in 1772, was among his next responsibilities.
At this time he declined the directorship of the Imperial Chapel, but did apply there two years later in 1774, failing in his application.
(Giuseppe Bonno became director of the Imperial Chapel instead, which had become open upon the death of Florian Leopold Gassmann.)