We show that exported products exit the US market sooner if they violate the Heckscher-Ohlin notion of comparative advantage. Crucially, this pattern is stronger when exporting country has a well-developed banking system, measured by a high ratio of bank credit over the GDP. Banks thus push firms away from exports that are facing an uphill battle on a competitive foreign market due to a suboptimal use of the domestic factor endowment. Our results imply a disciplining role for bank credit in terminating inefficient trade flows. This constitutes a new channel through which finance improves resource allocation in the real economy.