BRUSSELS — Western and Afghan officials gathered Wednesday for a feel-good conclave to pledge billions of dollars in development aid to the struggling country. The feel-bad topics may have been stuffed into a late-night news release the night before.

Announced with little fanfare, Europe just got Afghanistan to agree to accept an unlimited number of deportations of Afghan citizens. Volumes are expected to be so high that as part of the deal, “both sides will explore the possibility to build a dedicated terminal for return in Kabul airport.”

E.U. nations may want to deport up to 80,000 Afghan citizens whose applications for asylum have been rejected, according to internal documents that were leaked earlier this year. Under the deal, Europe would need to cap the number of deportees to 50 per flight for the next six months, but there is no limit on the number of flights.

The agreement shows the great lengths to which European leaders will go to reduce the numbers of migrants in their countries. Surging anti-immigrant sentiment helped British advocates for a divorce from the European Union win a referendum in June, and anti-migrant politicians are capturing posts across Europe.

The deportations to Afghanistan may be especially surprising, since the country is plagued by war and violence. E.U. countries have long deported Afghan citizens who were determined to have immigrated for economic reasons, if they are able to go back to less violent parts of the country. Critics say the criteria used to make these judgments are inconsistent and that E.U. citizens put people at risk when they are deported.

The deportation deal was not formally linked to the E.U. pledges of development aid to Afghanistan, but the connection was unmistakable, and E.U. leaders discussed it at the donors conference. At the conference, E.U. leaders agreed to give $1.5 billion a year in aid through 2020. Overall, Western governments offered more than $15 billion in aid.

“We do expect sending countries to take back irregular economic migrants, in line with international standards and obligations,” European Council President Donald Tusk said Wednesday. “That is why I want to thank the Afghan government for its courage in agreeing to a way forward to manage migration fairly in cooperation with the European Union. We will support this agreement with money and job-creation programs to reintegrate returning migrants to the benefit of their local communities.”

Read more: