We develop a political economy model of trade policy using a sector specific factor model with international capital mobility, looking for the relationship between protection and the composition of foreign capital. As foreign direct investment is remunerated at the marginal productivity of capital, an increase of the tariff raises its remuneration, increasing also the transfer of resources abroad. This is an additional cost of the tariff in terms of welfare. As external debt is remunerated at a given international interest rate, the additional cost of protection in terms of welfare does not appear. Then the equilibrium tariff with external debt is higher than with foreign direct investment. We present evidence for a panel of developing countries observed between 1970 and 1998 giving support to the main implication of the model. We find a significant effect of the composition of foreign capital on trade policy, implying that countries which have relatively more foreign direct investment than external debt also have less protection.