Germany has for the first time recognised it committed genocide in Namibia during its colonial occupation, with the government promising financial support worth more than €1 billion to aid projects in the southern African nation.
German colonial settlers killed tens of thousands of indigenous Herero and Nama people in 1904-1908 massacres - labelled the first genocide of the 20th century by historians - poisoning relations between Namibia and Germany for years.
While the German government had previously acknowledged that atrocities occurred at the hands of its colonial authorities, they have repeatedly refused to pay direct reparations.
"We will now officially refer to these events as what they are from today's perspective: genocide," said Foreign Minister Heiko Maas in a statement.
He hailed the agreement after more than five years of negotiations with Namibia over events in the territory held by Berlin from 1884 to 1915.
"In light of the historical and moral responsibility of Germany, we will ask forgiveness from Namibia and the victims' descendants" for the "atrocities" committed, Mr Maas said.
In a "gesture to recognise the immense suffering inflicted on the victims", the country will support the "reconstruction and the development" of Namibia via a financial programme of €1.1 billion, he said.
The sum will be paid over 30 years, according to sources close to the negotiations, and must primarily benefit the descendants of the Herero and Nama.
However, he specified that the payment does not open the way to any "legal request for compensation".
Namibia was called German South West Africa during Berlin's 1884-1915 rule, and then fell under South African rule for 75 years, before finally gaining independence in 1990.
Tensions boiled over in 1904 when the Herero - deprived of their livestock and land - rose up, followed shortly after by the Nama, in an insurrection crushed by German imperial troops.
In the Battle of Waterberg in August 1904 around 80,000 Herero, including women and children, fled and were pursued by German troops across what is now known as the Kalahari Desert. Only 15,000 survived.
German General Lothar von Trotha, sent to put down the rebellion, ordered the peoples' extermination.
At least 60,000 Hereros and around 10,000 Namas were killed between 1904 and 1908.
Colonial soldiers carried out mass executions; exiled men, women, and children to the desert where thousands died of thirst; and established infamous concentration camps, such as the one on Shark Island.
In 2015, Germany and Namibia started negotiating an agreement that would combine an official apology by Germany as well as development aid.
But in August last year, Namibia said that Germany's offered reparations were unacceptable. No details of the offer were provided at the time.
President Hage Geingob had noted Berlin declined to accept the term "reparations", as that word was also avoided during the country's negotiations with Israel after the Holocaust.
However in an effort to ease reconciliation, in 2018 Germany returned the bones of members of the Herero and Nama tribes, with the then foreign minister Michelle Muentefering asking for "forgiveness from the bottom of my heart".