The ongoing debate regarding the impact of rail infrastructures on equity has been a subject of continued interest, particularly in light of increased investments in transportation infrastructures. While numerous studies have explored the distributional impact of high-speed railway (HSR) on intercity economic disparity and accessibility changes, there’s less focus on equity within the city. Consequently, this study employs the difference-in-difference model to analyze the impact of HSR on equity within the city using prefecture-level data in China spanning 2006–2019. Additionally, the study examines the equity between cities, using the Wuhan-Guangzhou railway line as a case study. The findings reveal that the introduction of HSR not only directly enhances equity between cities by improving job accessibility but also indirectly diminishes the urban-rural divide by creating more job opportunities for rural residents. This study broadens the concept of horizontal equity by considering equity within the city and expands the investigation on the equity between cities from traditional accessibility studies to more focused job accessibility. Furthermore, the study contributes to understanding the equity impact of remittance behavior from rural-to-urban migrant workers on balancing urban-rural development, a phenomenon characterized by the quick urbanization of China and also popular in developing countries around the world.