Agriculture has been affected by climate change as well as infra structural changes in the process of grain production. Hence, the scale of dry farming in agro-pastoral ecotones of China has continued to increase, and its importance in ensuring farmland security and food security has become more prominent. However, the expansion of agricultural resource utilization has garnered considerable attention regarding the associated risk of resource overload and ecological vulnerability in agro-pastoral ecotones. This study considered Yulin City as an example and aimed to analyze the current status and trend of utilizing agricultural resources, such as climate, cultivated land, water, and germplasm, in recent years using methods such as center of gravity model, super-efficiency SBM model, and space-time analysis. The study also assessed the opportunities and associated problems, and identifies the optimal utilization mode of agricultural resources in agropastoral ecotones. The results showed that with ongoing climate change, the gravity center of cultivated land and grain production in Shaanxi Province witnessed a significant northward shift and moved northward between 1990 and 2019 by 38.40 km and 72.51 km, respectively. The scale of agricultural resource utilization and agricultural production in Yulin City has continued to expand in the last 30 years. The overall change in the trend of agricultural climate resources in Yulin City is conducive to agricultural production, which manifests as the increase of average temperature, accumulated temperature, precipitation, and frost-free period. Additionally, area under cultivation in Yulin City showed a trend of initial decline, subsequent increase, and final relative stability. Since 2000 the structure of grain plantation had changed, and the intensity of cultivated land use and production capacity increased significantly. The total amount of water resource utilization in Yulin City witnessed an increase, with an increase in the agricultural water use efficiency from 0.414 to 1.039 during 2010—2020. Here, we proposed three different modes of optimal utilization of agricultural resources: market-oriented, resourceintegrated, and ecological-leisure. These are suitable for areas with severe land degradation and decreasing population, rural areas with a certain resource base or industrial base, and urban suburban areas. [ABSTRACT FROM AUTHOR]