Saved

Press the star next to a tool's name to save it.

All my tools

Compost Calculator

Use this compost calculator to find the C:N ratio and moisture of a mix of up to three materials, and how much brown or green material to add to reach 30 to 1.

Restored your last values ·

%
%
%
%
%
%
%
%
%
More options
:1
%
%
%

Enter up to three compost materials: the mass as it comes, its moisture, and its carbon and nitrogen as a percent of dry weight. You get the C:N ratio and moisture of the mix. Describe an extra material to see how much to add to reach the target.

Everything is worked out in your browser. Nothing you type is sent anywhere.

–

–

Fill in material 1, and materials 2 and 3 if you have them, then press Calculate.

See full result

A compost calculator that works on the carbon to nitrogen ratio tells you whether a pile of materials is balanced. Enter up to three materials with their mass, moisture, carbon and nitrogen, and the calculator gives the mix's C:N ratio and moisture. Describe one more material and it shows how much to add to reach your target, usually 30 to 1.

How to use the compost calculator

  1. Choose US or metric units.
  2. Enter material 1: mass as it comes, moisture, carbon and nitrogen. Add materials 2 and 3 if you have them.
  3. Leave the target at 30 or type another ratio.
  4. Optionally describe an extra material to add, then press Calculate.

What the C:N ratio is

The carbon to nitrogen ratio compares the carbon and nitrogen in a material by weight. Cornell's composting pages give the relation as the percent carbon equal to the percent nitrogen times the C:N ratio [2]. For fresh grass with 2.4 percent nitrogen and 45 percent carbon, the ratio is 45 ÷ 2.4 = 18.75 [2]. The calculator shows the ratio of each material you enter.

The target of 30 to 1

Cornell's guide to composting ingredients says to aim for about 30 parts carbon to 1 part nitrogen by weight [3]. The Nebraska extension guide G2222 also gives about 30 to 1 as ideal [4]. As a general gardening note, and not a statement from those pages, a pile with too little carbon tends to stay wet and smelly, and one with too much carbon breaks down slowly. The default target here is 30, and you can change it.

Why moisture and dry weight matter

Materials contain water, and the carbon and nitrogen percentages are of the dry matter, so the mass as it comes has to be reduced to dry mass first: dry mass equals mass times 100 minus the moisture percent, divided by 100. Fresh grass at 77 percent moisture has only 23 percent dry matter, so 10 kilograms contain 2.3 kilograms of dry matter. The calculator does this for each material.

The mixing formula

The Cornell page on solving the moisture and C:N equations together defines the ratio of the mix, the mass, carbon, nitrogen and moisture of each material, but its equation is an image that we could not read as text [1]. We use the standard form, our own working: the mix ratio is the sum of dry mass times carbon for each material, divided by the sum of dry mass times nitrogen. This reproduces the page's result, as the next section shows.

The Cornell example

The page mixes 10 kilograms of grass (77 percent moisture, 45 percent carbon, 2.4 percent nitrogen) with 13.31 kilograms of leaves (35, 50 and 0.75) and 8.14 kilograms of food scraps (80, 42 and 5), with goals of a ratio of 30 and 60 percent moisture [1]. Our calculation gives a ratio of 30:1 and 60 percent moisture for the 31.45 kilograms, which matches. The three placeholder rows are this example.

Each material's own ratio

In the example, grass is 18.75:1, leaves are 66.67:1 and food scraps are 8.4:1. The extension guides list typical ratios: Cornell gives about 19:1 for grass and 40 to 80:1 for leaves [3], and Nebraska shows similar ranges and says the values are only guidelines [4]. Sources disagree on many materials, so use values for your own materials where you can.

How much to add

Describe an extra material by its moisture, carbon and nitrogen, and the calculator solves for the amount. With the dry carbon C and dry nitrogen N of the pile and a target R, the dry mass to add is (R × N minus C) ÷ (carbon of the new material minus R times its nitrogen). This is our own working. It is converted back to the mass as it comes using the moisture.

Checking the added amount

Cornell's C:N page says that 10 kilograms of grass need about 3.5 kilograms of leaves, which are 35 percent water, to reach 30 to 1 [2]. Our formula gives 3.474 kilograms, which rounds to 3.5. If you ignore moisture and treat everything as dry, the leaves needed rise to about 9.8 kilograms (our own working), so moisture changes the answer a lot.

When nothing can fix the pile

Not every material can bring a mix to the target. If the pile is short of carbon, you need a material whose own ratio is above the target, like leaves or straw. If it is short of nitrogen, you need one below the target, like grass clippings. The calculator tells you when the material you described is on the wrong side, and when the mix is already within half a percent of the target.

Using the calculator

Weigh your materials, estimate their moisture and look up their carbon and nitrogen. Start with the ratio and moisture. If the ratio is low, add brown material; if it is high, add green material. Rerun with the new masses. The Cornell example aims at 60 percent moisture, and a pile that is far wetter or drier needs water or dry material too. Use it as a guide, then watch the pile.

Keeping records

Write down the masses and the figures that you used each time you build a pile. When the pile heats up and breaks down well, you can reuse the recipe. When it does not, compare the result with the numbers in your notes and change one material at a time, so that you can see which change helped. Our own advice: trust a measured result over a table value.

Common mistakes

  • Using wet mass as dry mass. Take the moisture off first.
  • Treating guide values as exact. Ratios vary widely.
  • Adding a material of the wrong type. Carbon-rich fixes a low ratio.
  • Ignoring moisture. It changes the amount to add.

What next

Use this often? Add Compost to your Home screen.

Frequently asked questions

What is a compost calculator?

A tool that finds the carbon to nitrogen ratio and moisture of a mix of compost materials and how much to add to balance it.

What C:N ratio is best for compost?

Cornell and Nebraska extension guides give about 30 parts carbon to 1 part nitrogen by weight.

How do I find the C:N ratio of a mix?

Divide the total dry carbon by the total dry nitrogen, where each is the dry mass times its percent.

Why does moisture change the answer?

Carbon and nitrogen are percentages of dry matter, so wet materials contain less of both per kilogram.

How much leaves do I add to grass clippings?

Cornell says about 3.5 kilograms of 35 percent moisture leaves for 10 kilograms of grass, and the calculator gives 3.47.

What went wrong?

We only receive the reason you pick, never what you typed into the tool.

Thanks for your feedback.

More Everyday Life Tools