Carbon sinks in terrestrial ecosystems can be significantly increased by afforestation, which will slow global warming. However, it is still unclear how different plantations influence the carbon sink and how they respond to environmental factors, especially in drylands. In this study, eddy correlation method (EC) was used to measure carbon and water fluxes and environmental factors of two artificial forests (Larix principis-rupprechtii and Pinus tabulaeformis) in the dryland of Northwest China, and the responses of evapotranspiration (ET), net ecosystem exchange (NEE), gross primary productivity (GPP), and ecosystem respiration (RECO) to environmental factors were also assessed. Results showed that the L. principis-rupprechtii forest ecosystem had higher water use efficiency (WUE), light use efficiency (LUE), GPP, and RECO than the P. tabulaeformis forest ecosystem. However, the proportion of net ecosystem production (NEP) to GPP in the P. tabulaeformis forest ecosystem (62.89%) was higher than that in the L. principis-rupprechtii forest ecosystem (47.49%), indicating that the P. tabulaeformis forest ecosystem had the higher carbon sequestration efficiency. In addition, the CO2 and H2O fluxes in the L. principis-rupprechtii forest ecosystem were more sensitive to environmental factors, compared with the P. tabulaeformis forest ecosystem. Further, the RECO of the L. principis-rupprechtii forest ecosystem was more sensitive to temperature changes, which implies that the L. principis-rupprechtii forest ecosystem will release more CO2 than the P. tabulaeformis forest ecosystem with a warming climate. Therefore, the P. tabulaeformis forest ecosystem may have better carbon sequestration potential. These results are important for understanding the effects of climate change on the CO2 and H2O cycles in coniferous plantation ecosystems in drylands.