[Objective] Effects of grazing intensity on soil quality and plant diversity in saline marsh wetlands in arid northwest China were investigated to provide a reference for rational grazing and ecological restoration of arid desert wetlands. [Methods] Taking Baidunzi saline marsh wetland in Jingtai County, Gansu Province, China, as the study area, fenced exclusion, light grazing, and heavy grazing zones were established. Plant diversity and biomass were surveyed using the quadrat method, and soil samples were collected from different soil layers to determine aggregate composition, compaction, nutrient content, and physical properties. Principal component analysis (PCA) was used to construct a soil quality index (SQI) to assess the impact of grazing intensity on soil quality, and the structural equation modeling (SEM) was used to analyze the key influencing factors. [Results] ① Fenced exclusion increased plant biomass. β-diversity indices showed significant differences in species composition among different grazing intensities. The proportions of soil water-stable aggregates with particle size >0.25 mm, average mass diameter and geometric mean diameter of surface soil water-stable aggregates in the different grazing treatments were in the following order: no grazing > light grazing > heavy grazing. Soil fertility potential, soil fertility intensity and comprehensive soil quality in the no grazing zone were significantly higher than those in the heavy grazing zone, and there was no significant difference with those in the light grazing zone. SEM results revealed that soil dry sieve geometric mean diameter, soil nutrients (especially nitrogen and potassium), and capillary water-holding capacity were the main factors affecting soil quality. [Conclusion] Fenced exclusion improved vegetation growth and soil quality significantly. Moderate grazing (light grazing) positively feedbacks to the ecosystem by promoting aggregate stability and nutrient input, whereas heavy grazing leads to soil structure degradation and nutrient loss. A ‘fencing+moderate grazing’ management mode is recommended for prioritizing protection of surface soil physical structure and available nutrients to achieve sustainable restoration of saline marsh wetlands in arid regions.