Excessive car ownership in cities has led to issues including congestion, air pollution and resource consumption. This paper investigates the impact of rail transit openings on automobile purchases in China based on detailed car sales data during 2013–2015 and using two-way fixed effects panel models. Our study reveals an average decrease of 2.27 per cent in car sales due to rail transit openings. Further analyses of cars with different fuel economy reveal stronger effects on fuel-efficient cars, indicating larger substitution elasticity between public transportation and driving for people with less income. Results also show the negative impact of rail transit openings is larger in cities with more developed economies, higher public revenue, larger population, bigger area and fewer buses. The decline in car sales translates into savings of 7.9 billion liters of gasoline and a reduction of about 20.3 million tons in life-cycle carbon emissions.