Outside a youth refugee facility in Sicily, a group of teenagers from Gambia who had crossed the Mediterranean from Libya told me that farming had become too difficult to sustain in their country as the semiarid Sahel region spreads ever wider across the continent, drying up people’s land. In Yemen, years of water scarcity helped lead to the country’s brutal conflict.

El Salvador, one of the world’s most murderous countries, is just now recovering from a devastating drought, which only heightens the stakes and scope of the violence. In my book about youth migration from El Salvador, “The Far Away Brothers,” I write about a family that ended up on the wrong side of a gang-protected man in town. The family’s teenage twin brothers left because there was a price on their heads, but the challenges persisted for those who remained behind. The family’s fields produced less and less. The tomatoes took on a pallid, sickly color; other crops failed to grow at all. The family couldn’t survive from farming anymore, so more of the children considered going north. They haven’t yet, but nearly every day, one of the daughters tell me, she considers making arrangements to leave.

Many things are exacerbating the effects of the drought in Central America, including pervasive deforestation and farmers overtaxing their land. But according to Climatelinks, a project of the United States Agency for International Development, the average temperature in El Salvador has risen 2.34 degrees Fahrenheit since the 1950s, and droughts have become longer and more intense. The sea has risen by three inches since the 1950s, and is projected to rise seven more by 2050. Between 2000 and 2009, 39 hurricanes hit El Salvador, compared with 15 in the 1980s. This, too, is predicted to get worse.

When reporting a story among migrants living in the shadows of a Kenyan slum, I asked a group of men why they left their homes in rural Ethiopia. They were farmers there, like many generations before them, but they told me they could no longer make a living off their crops or even adequately feed their families. The rains had changed — it wasn’t just that they had lessened but that they had become more erratic; no rain when the crops needed it to grow, and then, when it was time for harvest, it would rain suddenly and terribly, ruining the crops. The men had left for Kenya to find work and send money back to feed their families.

Like El Salvador, Gambia, Bangladesh and Guatemala, Ethiopia has been hit hard by climate change, though it is not even in the top 100 emitters of greenhouse gases. But the problem with climate change, of course, is that it is a problem that crosses borders.

The anti-immigrant rhetoric of the Trump administration has made for elaborate and bombastic theater — but with real, and sometimes deadly, human consequences (see again the children separated from their parents at the border). But Mr. Trump means what he says: He wants immigration from poor countries to stop. He sees the problems in those countries as theirs, not ours — never mind the centuries of catastrophic foreign intervention in places like El Salvador and the rest of the Americas, the Arab world and sub-Saharan Africa, or the growing menace of the changing climate.

If President Trump really wants to curb “illegal” migration to the United States for the long haul, he’d better get serious about climate change. The Trump administration can continue to eviscerate the E.P.A. and thumb its nose at global efforts to protect the climate. Or he can work responsibly to try to curb international migration by addressing the challenges of a warming planet.

He can’t have it both ways.