A model of heterogeneous firms with multiple products and two production factors (labor and capital) is used to study how trade liberalization affects firms' choices through both product and factor markets. Trade liberalization is shown to always redistribute capital toward more efficient firms and always to improve an industry's total factor productivity. However, it may reduce capital prices and cause labor productivity to drop. Low efficiency firms are affected mainly by changes in the factor market, while high efficiency firms are affected mainly by changes in the product market. In response to trade liberalization, low efficiency firms always reduce their product scope, but high efficiency firms may expand their scope. The model demonstrates the importance of the interplay between product and factor markets.