Digital economy is an important direction of the new round of technological revolution and a key driving force for realizing the “double control of carbon emissions”. This paper utilizes the panel data of 30 provincial-level administrative regions in China from 2011 to 2021 to measure the development level of the digital economy, total carbon emissions, and carbon emission intensity and explores the impact of the digital economy on the dual control of carbon emissions and the mechanism of its effect by applying the mediating and moderating effect models. The results show that the digital economy can play a significant inhibitory effect on total carbon emissions and carbon emissions intensity, and this conclusion is still robust after a series of tests. From the government level, there exists a transmission path of “digital economy → environmental regulation stringency → dual control of carbon emissions”; from the enterprise and research organization level, there also exists a transmission path of “digital economy → R&D intensity → dual control of carbon emissions”. From the perspective of regional imbalance, there are large regional differences in the impact of the digital economy on the dual control of carbon emissions, and there are also large differences in the impact of the various subdivided indicators of the digital economy on the dual control of carbon emissions. In addition, this paper also finds that the positive effect of the digital economy on the dual control of carbon emissions is more obvious in regions with a smaller proportion of SOEs. These findings add new evidence to the study of “the impact of the digital economy on the dual control of carbon emissions” and provide new ideas for accelerating the realization of green and sustainable development.