(Wikipedia) - Even before diplomatic ties, unofficial relations had already taken root between the two nations. Goethe's dedication of his West-östlicher Divan (West-East Divan) to Hafez in 1819 is an illustration of how far back such cultural ties went.
However, the first recorded diplomatic contact between Iran and Germany was made in 1857. On the June, 25th of the same year, representatives from the two sides signed a Friendship and Trade agreement in Paris. Count Karl Franz Von Hatzfeld Wildenburg represented Germany while Farrokh Khan Aminolmolk who acted as the Persian ambassador to the Emperor of the French, Napoleon 3rd and Queen Victoria signed the agreement on behalf of Iran.
The Persian embassy was composed of the ambassador himself, accompanied by a suite of more than twenty persons, including councilors, interpreters, secretaries and writers. Six horses were given as present to the French Emperor, who expressed his regret about the ongoing conflict between Persia and the Great Britain, known as the Anglo-Persian War (1856-1857). Negotiations led to the March 1857 Treaty of Paris, which put an end to the Anglo-Persian War.
After his embassy, Ferouk Khan returned to Persia, where he became Prime Minister.
In 1860 a German delegation headed by Baron Julius Minutolik Freiherr was hosted at the court of Naseroddin Shah in Tehran for three months. Unfortunately, Baron Minutolik as Prussian Minister-resident and consul general to Persia passed away on November, 5 1860 at a Caravansaray near Shiraz , probably of cholera.
Naseroddin Shah visited Berlin in 1873 and expressed his willingness to expand ties with Germany mainly because Germans were not involved in the Great Game and Iranians saw them as a factor to counter-balance the British and Russian hegemony that was tearing the country apart. Following this trip a treaty was signed in Berlin between Prince Bismarck and Mirza Hossein Khan.