The German economy grew slightly in the first quarter of this year, supported by stronger investment, the Federal Statistics Office said today.

But the war in Ukraine began having an increasing impact from the end of February, the office added.

Europe's largest economy grew by 0.2% on the quarter in adjusted terms, the office said, adding that net exports had slowed growth. A Reuters poll had pointed to growth of 0.1%.

"The economic consequences of the war in Ukraine have had a growing impact on the short-term economic development since late February," the office added in a statement.

The German government on Wednesday cut its growth forecast for 2022 to 2.2% from 3.6% projected in January as Russia's invasion of Ukraine, sanctions and high energy prices take a toll on output.

It also raised its 2022 inflation forecast to 6.1%.

German Economy Minister Robert Habeck said the reduced growth forecast did not assume a Russian energy embargo or blockade and that the economy would tip into recession if either of those transpired.

Commerzbank economist Joerg Kraemer said companies and consumers were unsettled.

"If Russian gas supplies were halted, the energy crisis triggered by this would probably cause a deep recession. The economic risks are very high at the moment," he said.

A survey released during the week showed German consumer morale is projected to plunge to a historic low in May as the war in Ukraine leads to soaring costs for households and dashes hopes of a post-pandemic recovery.

German chemicals group BASF reaffirmed its 2022 profit forecast today, as its passes along soaring raw materials costs to its industrial customers, but warned that conditions globally were uncertain.

"The market environment continues to be dominated by an exceptionally high level of uncertainty," the company said.