Germany's government and the two major opposition parties have said they will jointly nominate Joachim Gauck, a human rights activist originally from East Germany, to be the country's next president.

Angela Merkel said her coalition government, and the centre-left opposition had rallied behind Gauck, 72, who was initially proposed by the opposition Social Democrats and Greens.

He is not a member of a political party.

"What moves me the most, is that a man who was still born during the gloomy, dark war, who grew up and lived 50 years in a dictatorship … is now called to become the head of state," Gauck said.

"This is of course a very special day in my life."

Christian Wulff, 52, resigned as president on Friday after two months of allegations about receiving loans on favourable terms and hotel stays from friends when he was state governor of Lower Saxony.

He was Merkel's candidate when elected less than two years ago, triumphing over Gauck in a messy election.

When Wulff resigned, Merkel immediately said she would work with the Social Democrats and Greens to find a consensus candidate to succeed him.

Merkel, who also grew up in East Germany, said her and Gauck's life stories strongly connected them. "We have both spent a part of our life in the GDR and our dream of freedom became true in 1989."

The chancellor said that clergymen such as Gauck – a former Lutheran priest – were at the forefront of the protests that eventually brought down the regime.

Claudia Roth, the Greens' leader, said "Gauck will restore the respect for the office, will restore dignity," to the presidency, which had become tainted by Wulff's actions.

While his name widely circulated as the opposition's favourite, it wasn't clear until Sunday whether the governing coalition would rally behind Gauck. At a press conference, Gauck said he was still stunned by the nomination, but "very late tonight, I will also be happy."