Former German Vice-Chancellor Frank-Walter Steinmeier has urged the country to "be brave" after being elected as the new German president with an overwhelming majority of the parliamentary assembly.

Steinmeier, who also served as Germany's foreign minister, claimed victory after receiving 931 of 1,260 of the votes cast in Berlin on Sunday (12 February).

The 61-year-old, who grew up in Detmold, West Germany, is a social democrat and was chosen by the Federal Assembly — a constitutional body convened solely for the purpose of electing a president. He had the support of current Chancellor Angela Merkel's grand coalition of centre-right and centre-left parties, according to AP.

The German president differs from the chancellor, as the role holds very little executive power and acts more as an important moral authority.

"Let's be brave, because then we don't have to be afraid of the future," said the German President-elect.

"Isn't it actually wonderful, that this Germany, our difficult fatherland, that this country has become an anchor of hope in the world for many,"

Steinmeier is usually diplomatic, but has strongly opposed US president Donald Trump and described the 70-year-old US leader as "a hate preacher" during the recent US election campaign. He also stated that the relationship between Germany and the United States could become "challenging", according to the BBC.

He will take up the post on 19 March and will succeed Joachim Gauck, who announced his decision to step down from the position after a single five-year term as he believed he was too old at 77. In his acceptance speech, he gave thanks to the outgoing Gauck before vowing to win the trust of the German people — including those who were not originally behind him.

"To those who have not supported me, I give a promise: I will (give) the same respect for the parties, [for] the government and the opposition, [for] the many voices in our democracy — I will work as a federal president to win your trust."

Berlin truck crash
Steinmeier went head-to-head with German Chancellor Angela Merkel in the German election of 2009. Sean Gallup/Getty Images

Steinmeier was the Social Democractic Party candidate who challenged Angela Merkel in the Federal Election in 2009, and the chancellor gave her backing to the elected man.

She called it "a good day for Germany", describing him as an excellent choice to succeed Gauck and one will have the support of most people in the country.