Lake sediment microbial communities vary across ecosystems and are often differentiated across pH. Additionally, these pH‐mediated differences in community composition are often correlated with changes in sediment functioning, such as methane and carbon dioxide production. However, few studies have experimentally tested pH effects on community assembly or considered how microbial community composition influences ecosystem function independent of differences in the environment. We used common garden experiments to test hypotheses about how pH influences microbial community assembly and function in lake sediments. Using inoculum from three acidic lakes and three near‐neutral lakes, we found that both pH environment and inoculum source significantly influenced sediment microbial community assembly. However, inoculum source had a larger effect size for both the sediment methanogen and nonmethanogen communities, indicating important roles of dispersal and drift. Additionally, inoculum source, but not pH environment, significantly influenced sediment methane and carbon dioxide production. This research is one of the first to experimentally test the influence of pH on sediment microbial community composition, and in doing so, we show the community composition significantly influences sediment function independent of pH. Understanding how lake sediment microbial communities are influenced by environment is the first step toward mechanistically linking changes in community composition to ecosystem function, and we provide critical evidence for how changes in microbial community assembly with environmental change will likely alter carbon cycling in lake sediments.