Former German foreign minister Frank-Walter Steinmeier has been elected president by a parliamentary assembly, BBC reports.
The Social Democrat, 61, is one of Germany's most popular politicians.
The post is largely ceremonial, but the president represents Germany abroad and is seen as carrying moral weight.
Mr Steinmeier was chosen by the Federal Assembly meeting in parliament in Berlin.
He won 931 out of 1,260 votes.