Earth system models demonstrate large uncertainty in projected changes in terrestrial carbon budgets. The lack of inclusion of adaptive responses of vegetation communities to the environment has been suggested to hamper the ability of modeled vegetation to adequately respond to environmental change. In this study, variation in functional responses of vegetation has been added to an earth system model (ESM) based on ecological principles. The restriction of viable mean trait values of vegetation communities by the environment, called 'habitat filtering', is an important ecological assembly rule and allows for determination of global scale trait-environment relationships. These relationships were applied to model trait variation for different plant functional types (PFTs). For three leaf traits (specific leaf area, maximum carboxylation rate at 25 °C, and maximum electron transport rate at 25 °C), relationships with multiple environmental drivers, such as precipitation, temperature, radiation, and CO<inf>2</inf>, were determined for the PFTs within the Max Planck Institute ESM. With these relationships, spatiotemporal variation in these formerly fixed traits in PFTs was modeled in global change projections (IPCC RCP8.5 scenario). Inclusion of this environment-driven trait variation resulted in a strong reduction of the global carbon sink by at least 33% (2.1 Pg C yr-1) from the 2nd quarter of the 21st century onward compared to the default model with fixed traits. In addition, the mid- and high latitudes became a stronger carbon sink and the tropics a stronger carbon source, caused by trait-induced differences in productivity and relative respirational costs. These results point toward a reduction of the global carbon sink when including a more realistic representation of functional vegetation responses, implying more carbon will stay airborne, which could fuel further climate change.