Acidification of agricultural soil is attributed to excessive reduced nitrogen (N) fertilizer application and enhanced nitrate leaching. However, after an initial pH decrease, an increase in soil pH was observed in a solar greenhouse study. Within the vegetable planting areas in China, 3.3 million hectares of vegetables are planted in similar solar greenhouses. The objectives were to clarify the origin of this alkalinity. The results showed that, from February 2009 to January 2010, the total H+ production rate by base cation (BC) uptake of tomato plants and applied N fertilizer was 50.4 kmol ha−1 yr−1 for the control (CK), 68.3 kmol ha−1 yr−1 for recommended N treatment (RN), and 68.9 kmol ha−1 yr−1 for conventional N treatment (CN). However, the alkalinity inputs by irrigation were 96.1, 76.0, and 71.3 kmol ha−1 yr−1 for treatment CK, RN, and CN, respectively. Considering the alkalinity inputs generated by lime‐containing chicken manure (CM) and plant removal of phosphorus (P), the net residual alkalinity was 47.6 kmol ha−1 yr−1 for CK, 25.5 kmol ha−1 yr−1 for RN, and 20.4 kmol ha−1 yr−1 for CN and resulted in a rise in soil pH of 0.6, 0.5, and 0.2 units, respectively. In addition, net BC accumulation caused by irrigation, P and potassium (K) fertilizers, and chicken manure was 68.5 kmol ha−1 yr−1 for CK, 104.3 kmol ha−1 yr−1 for RN, and 103.5 kmol ha−1 yr−1 for CN. Results indicated alkaline factors from irrigation water (IW) alleviated the acidification of greenhouse soil but may eventually accelerate soil salinization. Groundwater table declines because of overwithdrawal in the region may be responsible for the increases in base cations brought to the greenhouse soil by irrigation. Therefore, a better water management has to be considered in the region.