Abstract:Rural revitalization strategy has put forward higher requirements for rural development in China, and agriculture, as the cornerstone of rural development, plays an important role. At present, ecological environment issues are increasingly concerned, it is of great significance to safeguard the agricultural ecological environment by legal means. But at present, there are still some problems in the process of rural agricultural ecological environment rule of law, such as the legal system to be improved, the law enforcement system has defects, the legal team is weak, and the farmers’ consciousness of rule of law is weak. In order to protect the agricultural ecological environment, it is also necessary to improve the legal system of the agricultural ecological environment, improve the law enforcement mechanism, strengthen the strength of the team, optimize the legal environment, and let the countryside radiate the vitality of the new era.