Markups vary widely across industries and countries, their heterogeneity has increased overtime and asymmetric exposure to international trade seems partly responsible for this phenomenon. In this paper, we study how the entire distribution of markups affects resource misallocation and welfare in a general equilibrium framework encompassing a large class of models with imperfect competition. We then identify conditions under which trade opening, by changing the distribution of markups, may reduce welfare. Our approach is novel both in its generality and in the emphasis on the second moment of the markup distribution. Two broad policy recommendations stand out from the analysis. First, whenever there is heterogeneity in markups, be it due to trade or other distortions, there is also an intersectoral misallocation, so that the equilibrium can be improved upon with an appropriate intervention. This suggests that trade liberalization and domestic industrial policy are complementary. Second, ensuring free entry is a crucial precondition to prevent adverse effects from asymmetric trade opening.