Nitrogen (N) fertilizer application has revolutionized agricultural productivity, but excessive N fertilizer application has resulted in low N use efficiency (NUE) and high N accumulation, increasing the risk of N losses. Here, we hypothesize that the apparent N balance can be used as an indicator to identify the N input for obtaining high yield with a high NUE. Thus, a 12-year field experiment involving seven N treatments (0, 120, 240, 360, 480, 600, and 720 kg N ha–1 per year) in a typical winter wheat-summer maize rotation system in North China was conducted to investigate the response of crop yield and NUE to the N balance under different N application rates and to identify the N input–output framework. The annual yield increased in a linear-platform and NUE decreased with increasing N fertilizer application. The N balance and yield are strongly correlated to predict changes in yield, and a critical N balance of 44.4–64.9 kg N ha–1 per year was recommended for optimal yield with minimal risk of N loss. The N balance and NUE can be presented in the framework of N input–output, and the critical N input estimated from the N balance of 217–252 kg N ha–1 could obtain high productivity with high NUE (74.3–79.6 %). Overall, the apparent N balance could be used as a key indicator for optimizing N input, providing a strong reference for limiting N excess in intensive production areas and evaluating agronomic and environmental performance in N management. Data AvailabilityThe datasets generated during and analyzed during the current study are available from the corresponding author on reasonable request.