Both fertilizer and plant species richness may affect the soil nematode community. However, the influence of fertilizer and weed species richness interaction is unclear. Nematode abundance and biodiversity in wheat and weed plots soil treated with nitrogen, phosphate and potassium fertilizer addition and weed species richness (0, 1, 2 and 4 weed levels) were investigated in a long-term microcosm experiment established in 2010 at Kaifeng, China. The results demonstrated that fertilizer treatment increased the abundance of total nematode, bacterivores, and plant parasites whereas it decreased the total genera number, the Shannon—Wiener diversity index (H′), Margalef richness index (SR), the total maturity index (ΣMI), and structure index (SI), and degraded the structure of the nematode community. In contrast, weed species richness increased these ecological indices and enhanced the structure of the nematode community. Principal component analysis (PCA) indicated that the fertilizer’s effect was more significant than weed species richness. Redundancy analysis (RDA) demonstrated that fertilizer affected soil nematode mainly through increasing soil available phosphorus by 4.71 times and ammonium nitrogen content by 74.03%; weed species richness increased the diversity indices of soil nematode mainly through enhancing soil moisture by 2.07%. Our results suggest weed species richness may relieve the negative effect of fertilizer on the diversity of soil nematode community.