The effects of population growth (PG), dietary changes (DC), native rural-to-urban migration (NM), migration from regions distant from the cities (M), and agricultural patterns and practices (AP) on N use in food systems and the food trade, and on apparent and virtual nitrogen (N) and N use efficiencies (NUE), at the city scale, are not well understood. Here we selected seven Chinese cities as the study subjects, analyzed the food trade effects on apparent and virtual N inputs and NUE, and quantified the relative magnitudes of these factors on N inputs to cities' food systems during 1990-2015, by designing several scenarios. Our results show that food-sink cities are relying more and more on external food and feed, but in 2015 they transferred 33.8-74.9% of their N input for food or feed productions to areas outside their boundaries, and the food trade showed different effects on the virtual N cost of food N consumption. Apparent NUEs of food systems were 33.1-74.9% higher than those calculated from virtual N costs in Beijing, Tianjin, Shanghai, Lanzhou and Xiamen in 2015. But in cities that export large amounts of food and feed—for example, Chongqing and Changchun—apparent NUE was underestimated by 4.0-46.4% relative to virtual NUE. Native PG, DC, NM, M, and AP accounted for 1.2-14.1%, -6.6-30.0%, 0.6-8.2%, -7.7-131.0%, and -43.8-12.8%, respectively, of the increase in virtual N inputs associated with cities' food systems in 2015, compared to 1990. Our study concludes that M, DC, and AP changes should be considered for mitigating N input in these Chinese cities, and virtual N exports induced by the food trade should also be included if the city is a net food exporter. Selective food trade could help improve the NUE of cities' food systems, and virtual NUE should be used as an indicator, rather than apparent NUE.