Mesmer was born in the village of Iznang, on the shore of Lake Constance in Swabia, Germany, a son of master forester Anton Mesmer (1701—after 1747) and his wife, Maria/Ursula (née Michel; 1701—1770). After studying at the Jesuit universities of Dillingen and Ingolstadt, he took up the study of medicine at the University of Vienna in 1759. In 1766 he published a doctoral dissertation with the Latin title De planetarum influxu in corpus humanum (On the Influence of the Planets on the Human Body), which discussed the influence of the moon and the planets on the human body and on disease. This was not medical astrology. Building largely on Isaac Newton's theory of the tides, Mesmer expounded on certain tides in the human body that might be accounted for by the movements of the sun and moon. Evidence assembled by
Frank A. Pattie suggests that Mesmer plagiarized a part of his dissertation from a work by Richard Mead, an eminent English physician and Newton's friend. However, in Mesmer's day doctoral theses were not expected to be original.
In January 1768, Mesmer married Anna Maria von Posch, a wealthy widow, and established himself as a doctor in Vienna. In the summers he lived on a splendid estate and became a patron of the arts. In 1768, when court intrigue prevented the performance of La finta semplice (K. 51), for which the twelve-year-old Wolfgang Amadeus Mozart had composed 500 pages of music, Mesmer is said to have arranged a performance in his garden of Mozart's Bastien und Bastienne (K. 50), a one-act opera, though Mozart's biographer Nissen found no proof that this performance actually took place. Mozart later immortalized his former patron by including a comedic reference to Mesmer in his opera Così fan tutte.
De planetarum influxu in corpus humanum