Compost Magazine

Composting tips, advice and science.

Compost Science: Featured Image

The Science of Composting: How Compost Happens

Composting is a fascinating but complex process that involves chemical reactions, bacteria, fungi and multiple organisms. 

To be clear, you don’t need to understand the science of compost to be able to make compost! You may find, however, that an appreciation of the subtleties does make you a better composter. 

What is composting? 

There’s no common definition of compost or composting.

It’s sometimes defined as referring to hot composting, but you can achieve compost without heat. It’s also defined as a process that produces humus. Yet humus itself is controversial, with some scientists arguing it does not even exist. 

We’ve previously discussed the definition of compost and composting – and the disagreement around it –  in depth. 

A definition that does cover all bases is that composting is the act of collecting and storing organic material so it can decay and be added to soil to improve its quality. 

The decaying process involves multiple organisms breaking down that material into a form that: 

Do note that ‘finished’ compost has not finished decaying. While we can no longer see the organic matter, it continues to decay and release nutrients for some years.

Related: See our introductory guide to composting.

How compost is made

Anaerobic v. aerobic composting

There are two ways organic material can be broken down in the composting process. 

Anaerobic means ‘without air’, and anaerobic composting takes place when the conditions are not right for aerobic composting. Anaerobic composting takes place with food waste in landfills, but it can also take place in the home compost pile or bin when conditions are not optimal. 

Aerobic means ‘with air’. 

Aerobic composting has a number of benefits over anaerobic composting.

  • It’s faster.
  • Due to high temperatures, it’s more likely to kill diseases. 
  • It doesn’t produce unpleasant smells (caused by the production of ammonia).
  • As it produces C02 rather than methane, it is better for the environment

However, anaerobic composting may retain more nitrogen than aerobic composting.

The rest of this article will be talking about aerobic composting

The three phases of composting

Infographic demonstrating the three phases of compost. Royalty free - licensed under a Creative Commons Attribution 4.0 International License and can be re-used with attribution to this post.

Composting is often divided into three phases. 

Mesophilic stage: This stage is dominated by mesophilic bacteria. The compost heap starts to warm up as these bacteria give off heat. 

Thermophilic stage:As the heat increases, Thermophilic bacteria take over, creating an even hotter pile. 

Maturing stage: As thermophilic bacteria use up easily available proteins, fats, and complex carbohydrates, the compost enters the maturing stage. Tougher material is broken down, with more work done by physical decomposers. 

While the stages do run into each other, it does provide a good overview of how things work in an (optimum!) compost pile.

Let’s take a look in more detail. 


The composting process starts when compost materials are added to the compost pile. 

Microorganisms use chemicals in their body to break down those materials. This involves a number of chemical processes including oxidation, or the process of adding oxygen. Specifically, bacteria oxidize carbon to carbon dioxide, creating heat as they do so. 

Oxidation of carbon to C02 can release a great deal of heat. Washington State University estimates that for every gram of glucose processed in a compost heap, between 484 and 674 kcals of heat are released. 

Other chemical processes include reduction and hydrolysis

Compost Microorganisms 

Infographic showing the compost food web. Royalty free - licensed under a Creative Commons Attribution 4.0 International License and can be re-used with attribution to this post.
Data Source: Daniel L. Dindal: Ecology of Compost: A Public Involvement Project


Bacteria are single-celled organisms, and they are seriously small. The Rodale Book of Composting estimates it would take 25,000 to take up an inch on a ruler, and that there are up to one billion in a pea-sized amount of soil. 

Bacteria may be tiny, but there are seriously large quantities of them, and some scientists believe compost is predominantly made up of dead microbes. 

These bacteria include: 

Psychrophilic bacteria

These bacteria perform best at temperatures of around 13°C/ 55°F. But they’ll also work at lower temperatures, including at  -18°C/0°F! These bacteria give off a small amount of heat. If conditions are right, even when the weather is cold they can lead to the hotter conditions created by mesophilic bacteria. 

Mesophilic bacteria

Mesophilic bacteria, which are also present in soil, thrive at temperatures between 21°C/ 70°F to 32°C/90°F. These bacteria give off more heat, and if conditions are right they will get hot enough for thermophilic bacteria to start work. 

Thermophilic bacteria

Thermophiles are incredibly tough bacteria and may have been the first bacteria on earth. These bacteria prefer hotter temperatures and are most active at 46 – 60°C/ 115 to 140°F. 

The reason many composters aim for hot compost is that thermophilic bacteria work faster than other bacteria. The high temperatures they produce also kill pathogens and weed seeds. However, if the compost exceeds 71°C/160°F these bacteria will start to die off, slowing down the composting process. 

Nitrifying bacteria

Nitrifying bacteria often receive little attention when it comes to composting, but they play an important role in changing ammonium compounds to nitrates – which are then accessible to plants. There may be some overlap with other types of bacteria mentioned here. For example, some studies have found relations of nitrifying bacteria among thermophilic bacteria.


Actinomycetes, a higher form of bacteria that is similar to fungus, help to break down complex, woody materials which have been left behind by the thermophilic bacteria. These work best in moderate temperatures and produce long threadlike filaments which stretch throughout the compost. 

Learn more: The Mind-Boggling Role Of Bacteria In Compost


Fungi also help to break down tough materials. These can be more tolerant of heat and may start to appear in the thermophilic stages. 

The emerging role of viruses in compost

The role of fungi and bacteria is well-understood in composting. 

However, while we know that viruses play a role in nutrient recycling in the sea, their function in soil and compost is less well-understood. 

One recent study did offer a glimpse into their possible function. 

The researchers found that in very hot industrial composting DNA viruses improved nutrient recycling. 

Some viruses did this by breaking down bacteria and using their genes to break down organic material – while at the same time adding mass from the bacteria to the compost. 

Other viruses actually seemed to benefit the bacteria, by increasing their ability to survive under environmental stress.

This study did focus on composting at very hot conditions (up to 90 degrees celsius), so we need more research to understand their role in composting in cooler conditions.

Physical decomposers

Bacteria aren’t the only things working away in your compost heap. Bacteria attracts larger organisms searching for food, while those larger organisms attract bigger organisms again.

Decomposers are classified into primary, secondary and tertiary consumers.

Primary consumers, which include both bacteria and also larger decomposers such as worms, slugs and snails, eat the plant material.

Secondary consumers eat primary consumers, and tertiary consumers eat secondary consumers (and each other). 

For example, nematodes will appear and start eating the bacteria. Nematodes are microscopic worms and according to Michelle Balz, author of Composting For A New Generation, are the most abundant physical decomposer in a compost pile. 

Fungi are eaten by springtails which in turn are eaten by centipedes and pseudoscorpions. Files, beetles and millipedes are all eaten by soil flatworms. 

Many of these physical decomposers are visible to the eyes – you will recognize worms, woodlice, slugs, snails and other creatures. 

Worms are particularly important in this process. They create tunnels in the compost which allows air and oxygen to circulate and nutrients to pass through the pile. 

They also take in organic material and pass it through a digestive process rich in hormones, enzymes and fermenting processes. They help produce a rich, fertile compost which is great for soil.

Requirements for aerobic composting

Nutrients needed

Bacteria, actinomycetes and fungi need nutrients to live and reproduce. 

Two of the frequently mentioned are carbon and nitrogen.

Carbon is used as an energy source and a building block. Nitrogen is used to build proteins and other elements. Getting the right mix of carbon and nitrogen can help provide an optimum environment for composting. 

Bacteria also require phosphorus and potassium, as well as tiny quantities of minor elements. 

Manure is a good compost material because it is rich in both nitrogen and phosphorus – it is even better when combined with carbon-rich straw. However, some manure may contain herbicides which can affect plant growth.

Material composition

Not all materials are equal when it comes to composting, even when taking nutrients out of the equation. 

Woody material is full of tough materials like lignin and cellulose, which bacteria find hard to break down. Large wooden materials are best shredded, before being added to the compost pile. They can also be buried and allowed to decompose slowly over time. This is the method used in Hugelkultur.

On the other hand, materials containing simple carbohydrates and sugars, such as food waste, are broken down easily by bacteria into simple sugars, organic acids and carbon dioxide. 

Material size

Smaller particle sizes mean there is a large surface area for the bacteria to work on.

Reducing the size of the materials added can play a major role in speeding up the composting process. This is especially helpful with woody material.


A large compost heap is important because the outer layers create insulation. This prevents the warmth treasured by heat-seeking bacteria from escaping. The process can be simulated with insulated compost bins


Aerobic bacteria require oxygen to survive and for the chemical processes that digest compost material. While compost bacteria can survive on as little as 5% oxygen, when the pile starts to fall below levels of about 10%, parts of the pile may start to switch to anaerobic decomposition. 

Oxygen levels will start to fall naturally as microbial activity increases and use oxygen. As this activity slows, the oxygen levels will rise again


Water is essential for microorganisms to survive. However, if there’s too much water in the compost heap, it is difficult for microorganisms to access oxygen. The composting process will slow, and anaerobic composting may take place.

As we explored in 16 Ways to Speed Up Your Compost, small changes in moisture level can make a big difference to composting speed.

PH levels

While the ideal range for microbial activity is 6.5 to 8.0, overall compost is fairly tolerant of PH levels. That’s partly because different bacteria perform well with different PH levels. 

PH levels will also vary during the composting process. During the first few days of composting, the PH levels could drop as low as 4 as organic acids are formed, and by the end of the process, PH levels end up between 7.5 and 8.0. 

Sources and further reading 

Best Books for Learning More

The Humanure Handbook is about a lot more than composting human waste, and references many studies on composting. It’s also the most entertaining read of the books listed here.

The Composting Handbook is a fantastic resource that explores both the science and gives practical tips aimed at larger-scale composting. However, the price of this book will put a lot of amateur composters off.

Compost Science for Gardeners has a very clear introduction into the science of composting for a layperson.

I have also found the Rodale Book of Composting a good introduction to some of the science of composting – especially chapter 3: Life Inside A Compost Heap and chapter 4: Compost and Plant Health.

Image rights

Creative Commons License
The Compost Stages and Compost Food Web mini infographics by are licensed under a Creative Commons Attribution 4.0 International License. They can be re-used with attribution to this post. Full size images are available upon request.