In a seminal paper, Helpman et al. (2008) demonstrate that accounting for self-selection and firm heterogeneity is crucial for obtaining unbiased estimates in the gravity equation. In this paper, we show how this insight helps solve the trade elasticity puzzle that, hitherto, trade elasticity estimates in the gravity equations have implied very small welfare gains from trade. To apply their approach to product-level data, we propose new exclusion restrictions based on the export learning literature. Our new estimates imply much larger welfare gains from trade than the previous literature suggested.