The mood among German investors worsened slightly in June, but their assessment of the German economy's current condition improved mainly due to healthier growth in the European Union.
The Mannheim-based ZEW research institute said its monthly survey showed its economic sentiment index fell to 18.6 from 20.6 in May.
The Reuters consensus forecast was for a rise to 21.5.
A separate gauge measuring investors' assessment of the economy's current conditions rose to 88 from 83.9 last month. This compared with the Reuters consensus forecast which predicted a reading of 85.
Meanwhile, an upturn in Europe's biggest economy is continuing during the second quarter, helped by noticeable rises in private and state spending and by an expansion in industrial production.
This is according to the German economy ministry's latest monthly report.
"In the slightly revived global environment, German exports remain pointing upwards," said the ministry.
It added that it also saw a continuation of the trend of a falling current account surplus, in evidence since mid-2016.
The German economy grew 0.6% quarter on quarter in the first three months of the year, driven by strong exports, booming construction and higher household and state spending.