Understanding the key roles of nutrient elements in soil–plant systems are essential for herbal medicine production and sustainable development. However, the ecological relationships between soil quality and nutrient elements, yield, saponins, or other active compounds in American ginseng remain unclear. In this study, 20 soil indicators, 10 root nutrient indicators, 9 quality indicators, and yields were investigated. The minimum dataset was constructed by principal component analysis, key factors were screened by correlation analysis and PLS-PM analysis, and the prediction model was constructed using linear fitting and tested by a validation test. The minimum dataset, constructed based on principal component analysis, comprised five indicators: SOM, TP, AK, AMg, and ACa. Correlation analysis, PLS-PM analysis, and linear fitting showed that K and Mg were the key factors relating soil quality to the yield and quality of American ginseng and that when AMg was 0.21 g/kg and AK was 0.30 g/kg, soil organic matter was 27%, total phosphorus was 1.19 g/kg in soil, K content in roots was 15.63 g/kg, Mg content was 1.91 g/kg, and the K/Mg of 8.85 could balance American ginseng yield and quality. In predicting and validating the model, predicting the DW, total ginsenoside, Rb1, Rb2, Rc, and Rd of American ginseng using K/Mg were reliable. This study provides a scientific basis for nutrient regulation, selecting planting sites, assessing soil quality, and predicting and evaluating American ginseng quality.