At routine events or on the campaign trail, Merkel was met with masses of people whistling and heckling.
"Resign!" a crowd in Dresden chanted on Germany Unity Day in 2016.
The CDU's traditional Bavarian allies -- the more conservative CSU -- have insisted on annual quotas for the number of migrants allowed into the country.
Merkel long resisted such calls before finally giving in, in all but name.
Parliamentarians quickly passed tougher asylum laws that contributed to a sharp reduction in the number of new requests, from a peak of 750,000 in 2016 to 158,000 between January and October this year.
And endless calls to be tougher about deporting rejected asylum seekers have seen charter flights take Afghans back to Kabul.
Some politicians have even urged that people should be returned to parts of Syria.
'Not just Merkel'
With migration dominating the airwaves, the far-right Alternative for Germany (AfD) party began notching up electoral wins after years of stagnation.
It has become the strongest party in certain regions, winning 92 seats in the Bundestag (lower house) 2017 parliamentary election, promising to "hunt" Merkel.
Such a major presence for the far-right in parliament has not been seen in Germany since 1945, as the country's strong memory of the Nazi past restricted xenophobia's appeal.
Meanwhile the CDU's record low in 2017 prompted the party's conservative wing, which had always bridled at Merkel's centrist leadership, to turn up the volume on its complaints.
It took six months for the chancellor to form her fourth government, and the shaky alliance has been riven by repeated clashes over migration -- fed by the disunity in the conservative camp.
After a string of setbacks in regional elections, Merkel announced in October that she would not stand for reelection as party chief this month -- nor for reelection as chancellor in 2021.
"Maybe it's a good thing that she's leaving, so that a new generation can emerge," said Syrian refugee Rihawi.
In any case, "it wasn't just her, but the Germans who opened their doors to us," he added.
Opinion polls give some support for that view, with the ecologist, pro-refugee Greens party currently flying high above both the AfD and the CDU's traditional foes, the Social Democrats.