Natural ecosystems provide services such as ameliorating the impacts of deleterious human activities on both surface and groundwater. For example, several studies have shown that a healthy riparian ecosystem can reduce the nutrient loading of agricultural wastewater, thus protecting the receiving surface water body. As a result, in order to develop better protection strategies and/or restore natural conditions, there is a growing interest in understanding ecosystem functioning, including feedbacks and nonlinearities. Biogeochemical transformations in soils are heavily inﬂuenced by microbial decomposition of soil organic matter. Carbon and nutrient cycles are in turn strongly sensitive to environmental conditions, and primarily to soil moisture and temperature. These two physical variables affect the reaction rates of almost all soil biogeochemical transformations, including microbial and fungal activity, nutrient uptake and release from plants, etc. Soil water saturation and temperature are not constants, but vary both in space and time, thus further complicating the picture. In order to interpret ﬁeld experiments and elucidate the different mechanisms taking place, numerical tools are beneﬁcial. In this work we developed a 3D numerical reactive-transport model as an aid in the investigation the complex physical, chemical and biological interactions occurring in soils. The new code couples the USGS models (MODFLOW 2000–VSF, MT3DMS and PHREEQC) using an operator-splitting algorithm, and is a further development an existing reactive/density-dependent ﬂow model PHWAT. The model was tested using simplified test cases. Following verification, a process-based biogeochemical reaction network describing the turnover of carbon and nitrogen in soils was implemented. Using this tool, we investigated the coupled effect of moisture content and temperature ﬂuctuations on nitrogen and organic matter cycling in the riparian zone, in order to help understand the relative sensitivity of biological transformations to these processes.