Replication codes for Wei Lu, Yi Wei and Yunxia Fan (2026). “Educational competition and reduced family size in China”, forthcoming in Demographic Research Instructions to replicate the results in the paper with Stata 16.0. The main file is "regress.do". This core Stata do-file is designed specifically to replicate the empirical regression results presented in Table 1, Table 3, Table 4, Table 5, and Appendix Table B2 of the paper. However, we do not provide the original raw data in the replication package due to data access constraints. The data are mainly obtained from Dianping.com (2019 academic private tutoring centers) and the 2022 Survey on the Usage of Educational Informatization in Primary and Secondary Schools in China by Peking University. Following the implementation of China's "Double Reduction" policy in 2021, all information related to private tutoring centers (PTCs) was removed from Dianping.com, making these historical data no longer publicly available. Readers interested in these data may contact the authors for potential cooperation. The 2022 Survey on the Usage of Educational Informatization in Primary and Secondary Schools in China is also not publicly accessible. Readers may contact the authors for further details. Another do-file named "figure.do" is used to generate Figure 1 and Figure 2 in the paper. We also provide two corresponding datasets: "BirthRate_China" and "population_China", which can be used to replicate the results shown in Figure 1 and Figure 2. Additionally, the three maps in the appendix (Figure A1, Figure A2, and Figure A3) were created using ArcGIS 10.8 without any replication code. Figures A1 and A2 use the aforementioned PTC data from Dianping.com, while Figure A3 employs city-level birth rate data in China, which is available in the provided dataset "Birthrate_China".