The international mobility of low-skilled workers is constrained by immigration restrictions set by rich countries, preventing extreme poverty from declining in the developing world. Under aversion to extreme poverty, one country's immigration policy affects the welfare of other countries: "nationalist" political decisions are subject to a prisoner's dilemma. Taking advantage of efficiency gains from coordination, we propose an alternative allocation of labor, which minimizes extreme poverty while keeping rich countries as well off as in the nationalist situation. This allocation can be decentralized through international taxes and subsidies. Numerical simulations show that the role of aversion to poverty is negligible when considering each country separately, but becomes important for the design of a coordinated migration policy.