From Wall Street Journal. Story by Anton Troianovsky.

German Chancellor Angela Merkel is stepping up her efforts to stem migration to Europe at the source, flying to Africa this weekend and working to convince Germans that better conditions in developing countries are in their own interests.

In a three-day swing through Mali, Niger, and Ethiopia starting Sunday, Merkel will discuss German development aid and ways to prevent young Africans from attempting the perilous land-and-sea journey to Europe. After she returns, she will meet the presidents of Chad and Nigeria in Berlin next week.

The flurry of diplomacy underscores how deeply the refugee crisis is affecting the foreign policy of the European Union’s most populous country. While German exporters have long done business all over the world, Berlin’s influence in Africa has been minuscule compared with former colonial powers such as France and Britain.

Now Merkel is trying to convince Germans that the refugee crisis should change that. In Africa, she argues, Germany needs to spend more on development aid as stubborn poverty and the spread of the Internet combine to push more people to make their way to Europe. Berlin and Brussels are also pushing countries to take back migrants who made it to Europe and had their asylum applications rejected.

“I am convinced that our security, our life in peace and our sustainable development is connected with the living situation of people who live far away from us,” Merkel said in an interview in the newspaper Die Zeit published Thursday. “The more people in the world know about us, the more we must deal with them.”

Merkel’s Africa push is also part of a broader European effort to strike deals with developing countries aimed at stemming, or reversing, migration. While European leaders say such agreements are necessary to stop migrants from making the sea crossing in the first place, critics say deals with often authoritarian regimes undermine the E.U.’s commitment to human rights.

On her Africa tour, her first multiday trip to Africa since 2011, Merkel will visit Niger, which German officials say is the most important hub for Africans seeking to make it to the Libyan coast and on to Europe. German government officials are drawing up plans for development projects there including vocational training and infrastructure. Merkel noted in a speech last week that Niger’s population has an average age of 15.2 years, compared with 44.9 years in Germany.

“We must give these countries hope for the future,” Merkel said. “We must also push them to adopt better governance.”

In a speech to German businesspeople Wednesday, Merkel urged them, too, to invest in Africa.

“Let me encourage all of you to show more openness in the direction of this continent,” she said. “Especially since the population in Europe’s neighboring continent is expected to double in the next 35 years.”