Andrea Nahles, the leader of Germany’s junior coalition partner, the Social Democrats (SPD), has announced her resignation, raising concerns that Angela Merkel’s government might collapse.

Nahles, who will step down from all her political roles including that as leader of the SPD parliamentary group, said her resignation was a consequence of the poorest ever performance from the SPD in its 156-year history last weekend, when it received just 15.8% of the vote at the European parliamentary elections, 11 points down on 2014.

In a statement, Nahles, who became party leader in April 2018, and joined the parliamentary group in September 2017, said: “I took over the chair of the party and parliamentary group in difficult times. We decided together, as part of the German government, to carry responsibility for our country. At the same time we worked on trying to re-erect the party and to win over citizens with new contents.

“To achieve both is a big challenge for all of us. Mastering these requires complete mutual support.” She added that over the past weeks “the great deal of feedback I’ve had from the party has shown me that the necessary backing … is no longer there.”

Nahles’s decision plunges both the party and the future of the 15-month-old so-called grand coalition with the Christian Democrats (CDU) under Merkel into doubt.

The future of the coalition now depends on the decision as to who succeeds Nahles. Anyone more to the left of the party might consider collaboration with the CDU unworkable and could push for a departure from the coalition. While a minority government might be tolerated, it is more likely that such a decision would trigger new elections, and probably lead to the premature end of what Merkel has declared is her final chancellorship.

The CDU was on Sunday sending out the message that it was in favour of keeping the grand coalition afloat.

Many SPD members were sceptical about the party entering its third coalition in four terms with the CDU, with concerns rife that the party would struggle to assert its own identity – despite key achievements such as the introduction of a minimum wage. Many are convinced the SPD’s close association with the CDU has increasingly damaged them at the polls.

Nahles had initially said she wanted to stand for re-election on Tuesday. Her surprise announcement on Sunday after, she said, “a night of reflection” and driven by her desire to give the party a chance to find a successor “in an orderly manner”, has sent shockwaves through the political establishment.

Ralf Stegner, the deputy chair of the SPD, said Nahles’s decision deserved “the highest respect”, adding that the behaviour of the party during the past weeks had not been in keeping with the Social Democrats’ core value of solidarity. “If we want to win trust and overcome this grave crisis, something fundamental has to change,” he said.

Dietmar Bartsch, parliamentary leader of the leftwing Die Linke, paid tribute to Nahles, but criticised the ongoing row within the SPD. “Politics should not be as brutal as this,” he said. “Perhaps we all need to simply take a step back.”

The co-chair of the far-right Alternative für Deutschland (AfD) Alice Weidel said the days of Merkel’s government were numbered.

“It’s not just the SPD that is falling apart, but also the GroKo [grand coalition], which is wandering like the undead over the political stage.” She added: “Each day more and more limbs are falling off it.”

The former SPD leader Sigmar Gabriel said the party was racked with inner turmoil, with Nahles’s resignation a sign that it needed a “detoxification”.

He said: “As long as the party is only concentrated on itself, as long as it is only concerned with the enforcement or prevention of internal party positions, people will continue to desert us.”

Nahles is the first woman to have led the SPD, which is the oldest party in the German parliament, its roots going back to 1863.

After the SPD’s poor showing in the 2017 general election when it secured just 20.5% of the vote, much pressure was put on the leadership, including by its membership base, to reject joining a grand coalition once again.

But Nahles argued vehemently that it was part of the party’s tradition to act in the national interest first, arguing that with the AfD’s entry into the Bundestag for the first time, and after the collapse of coalition talks between the pro-business FDP and the Green party, the SPD had a moral duty to help form a government. The formation of the grand coalition meant the AfD became the strongest opposition party in parliament.

Malu Dreyer, leader of the state of Rhineland-Pfalz, is being tipped as Nahles’s interim successor, though she is said to have been resisting the calls because she has multiple sclerosis, and went public with the diagnosis in 2006.