The increasingly serious destruction of the natural environment represents a great threat to the sustainable development of human beings and the earth. Under pressure from the government and public opinion, companies must assume environmental responsibility; however, there is no conclusion on whether corporate environmental responsibility is beneficial to companies. From the perspective of investment efficiency, this paper collects panel data from Chinese listed companies from 2011 to 2016 to discuss the impact of corporate environmental responsibility on investment efficiency and the moderating role of the institutional environment and consumer environmental awareness. The results show that corporate environmental responsibility can significantly positively affect investment efficiency, but this effect is not a short-term effect; it needs time to play a role. Second, in regions with a good institutional environment, corporate environmental responsibility has a more significant impact on improving investment efficiency. Finally, with the improvement of consumer environmental awareness, companies that assume environmental responsibility can address underinvestment. The research in this paper supports stakeholder theory, indicating that corporate environmental responsibility is not “selfless dedication”. In addition, the research results of this paper are robust and not subject to endogenous influences.