Track and reduce CO2 emissions from your computing

AI can benefit society in many ways but, given the energy needed to support the computing behind AI, these benefits can come at a high environmental price.

CodeCarbon is a lightweight software package that seamlessly integrates into your Python codebase. It estimates the amount of carbon dioxide (CO2) produced by the cloud or personal computing resources used to execute the code.

It then shows developers how they can lessen emissions by optimizing their code or by hosting their cloud infrastructure in geographical regions that use renewable energy sources

What it is

  • A lightweight and easy-to-use Python pip package

  • Emissions tracked based on your power consumption & location-dependent carbon intensity

  • Effective visualization of outputs in an integrated dashboard

  • Open-source, free, and driven by the community

Calling out : Read more on Medium


A single datacenter can consume large amounts of energy to run computing code. An innovative new tracking tool is designed to measure the climate impact of artificial intelligence.

Kadan Lottick, Silvia Susai, Sorelle Friedler, and Jonathan Wilson. Energy Usage Reports: Environmental awareness as part of algorithmic accountability. NeurIPS Workshop on Tackling Climate Change with Machine Learning, 2019.

How it works


Visualizing the outputs & insights

Emissions for individual code repositories based on infrastructure and power consumption.

Exemplary equivalents to put emissions in context.

Recommends compute regions with lower carbon intensity for major cloud providers – AWS, Azure, and GCP.

Call for action

Use CodeCarbon, Contribute to its development, and spread the word !

We look forward to developers and researchers using the tool and sharing their feedback

We look forward to developers contributing to CodeCarbon development

We also encourage you to spread the word about CodeCarbon among your colleagues and peers in conferences, on social media platforms, and developer forums

CodeCarbon is maintained by these contributor

Here is the team that built CodeCarbon. Join us and help improve CodeCarbon !

CodeCarbon was developed by four partner organizations and is made freely available to the community.


Clever Cloud is an IT Automation platform. They manage all the ops work while you focus on your business value.
Clever Cloud is supporting the project by providing us free hosting for the Code Carbon API.