This study examines whether information about a firm's engagement in environmental, social, and governance (ESG) practices is material to market participants. Evidence from a sample of 1856 initial public offerings (IPOs) by U.S. companies for the 2007–2018 period robustly documents that firms for which there is available ESG performance information prior to going public exhibit higher underpricing due to a positive market response. Such a reaction is validated by agency cost-reducing practices that ESG-rated firms follow prior to the IPO, the superior post-IPO market performance they exhibit in terms of equity financing, and the higher share of financially sophisticated investors they attract compared to their ESG-unrated peers. Overall, our results highlight that it pays off to do good and to have the right investors; however, firms’ good ESG practices need to be visible to the market, through rating practices, to reap the benefits.