Mosses need to be incorporated into Earth system models to better simulate peatland functional dynamics under changing environment. <i>Sphagnum</i> mosses are strong determinants of nutrient, carbon and water cycling in peatland ecosystems. However, most land surface models do not include <i>Sphagnum</i> or other mosses as represented plant functional types (PFTs), thereby limiting predictive assessment of peatland responses to environmental change. In this study, we introduce a moss PFT into the land model component (ELM) of the Energy Exascale Earth System Model (E3SM), by developing water content dynamics and non-vascular photosynthetic processes for moss. The model was parameterized and independently evaluated against observations from an ombrotrophic forested bog as part of the Spruce and Peatland Responses Under Changing Environments (SPRUCE) project. Inclusion of a <i>Sphagnum</i> PFT with some <i>Sphagnum</i> specific processes in ELM allows it to capture the observed seasonal dynamics of <i>Sphagnum</i> gross primary production (GPP), albeit with an underestimate of peak GPP. The model simulated a reasonable annual net primary production (NPP) for moss but with less interannual variation than observed, and reproduced above ground biomass for tree PFTs and stem biomass for shrubs. Different species showed highly variable warming responses under both ambient and elevated atmospheric CO<sub>2</sub> concentrations, and elevated CO<sub>2</sub> altered the warming response direction for the peatland ecosystem. Microtopography is critical: <i>Sphagnum</i> mosses on hummocks and hollows were simulated to show opposite warming responses (NPP decreasing with warming on hummocks, but increasing in hollows), and hummock <i>Sphagnum</i> was modeled to have strong dependence on water table height. Inclusion of this new moss PFT in global ELM simulations may provide a useful foundation for the investigation of northern peatland carbon exchange, enhancing the predictive capacity of carbon dynamics across the regional and global scales.