From 1736 to 1738 he studied theology at the University of Halle before becoming a teacher in Ratisbon. In 1760, the university of Wittenberg gave him the title of Doctor of Philosophy, and the University of Tübingen awarded him in 1763 the title of Doctor of Divinity. In 1741, he became the pastor und in 1779 the dean of the Protestant parish in Ratisbon.
In 1759, Schäffer published Erleichterte Artzney-Kräuterwissenschaft, a handbook of botany and the medicinal effects of plants for doctors and pharmacists. From 1762 to 1764, he wrote four richly illustrated volumes on mycology, Natürlich ausgemahlten Abbildungen baierischer und pfälzischer Schwämme, welche um Regensburg wachsen. In 1774, he wrote Elementa Ornithologica, in which he proposed a system of classification of the birds based on the structure of their legs. This work was followed by Museum Ornithologicum in 1789, in which he described the birds in his collection. In 1779, Schäffer published the three-volume work Icones insectorum circa ratisbonam indigenorum coloribus naturam referentibus expressae, which included 280 hand-coloured plates of copper engravings, illustrating approximately 3,000 insects. An introduction to entomology, Elementa entomologica, followed in 1789.
Schäffer organised a rich personal cabinet of curiosities, the Schaefferianum Museum, opened to the public and which Goethe (1749–1832) visited in 1786 at the time of the "voyage" which led him to Italy. He was a member of many learned societies such as those of Göttingen, Mannheim, Saint-Petersburg, London and Uppsala. He was a corresponding member of the Académie des sciences (Academy of Science) of Paris and joined, in 1757, the Kaiserlich-Carolinische Akademie der Naturforscher, and two years later took part in the foundation of the Bayerischen Akademie der Wissenschaften. Schäffer maintained a correspondence with many naturalists including Carl von Linné (1707–1778) and René Antoine Ferchault de Réaumur (1683–1757). In Feb 1764 he was elected a fellow of the Royal Society He was the first to describe Ramaria flavescens.
Natural history was not the only field which interested him. He conducted experiments on electricity, colours, and optics. He remains famous for his manufacture of prisms and lenses. He invented an early washing machine, for which he published designs in 1767: Die bequeme und höchstvortheilhafte Waschmaschine. His other inventions included a saw and furnaces. The paper industry also interested him and between 1765 and 1771 the results of his observations and experiments were published as Versuche und Muster, ohne alle Lumpen oder doch mit einem geringen Zusatze derselben, Papier zu machen. It discussed in particular the manufacture of paper using various plants such as the poplar, moss and hop, which might not have been used by the paper pulp manufacturers without his experimental work.