A compost pile works best when its microbes get roughly 25 to 30 parts of carbon for every part of nitrogen. Too much nitrogen and the pile smells of ammonia; too much carbon and it barely heats up. Gardeners talk about "greens" and "browns", but the materials differ enormously: grass clippings sit near 17:1, autumn leaves around 54:1 and cardboard above 500:1. This compost calculator replaces guesswork with arithmetic.
List what goes into the pile and how much of each — kilograms, pounds or simply buckets weighed once. The calculator looks up typical nitrogen, carbon and moisture values from the On-Farm Composting Handbook (NRAES-54), sums the carbon and the nitrogen of the whole mix, and returns the C:N ratio and the moisture content. If the ratio is outside the 25–30:1 range, it tells you how much of a brown or green material of your choice to add to bring it to 30:1, and how much water a dry pile needs.
Have a lab analysis of your manure or food waste? Type its nitrogen, carbon and moisture into the row and they replace the typical values.
How to use this calculator
- Add one row per material and choose it from the list, or pick Custom and type its %N, %C and moisture.
- Enter each wet weight as it goes on the pile, all in the same unit.
- Optionally type lab values for %N, %C (dry basis) or moisture to override the typical ones.
- Choose the brown you would add if the mix is too rich in nitrogen, and the green you would add if it is too poor.
- Read the C:N ratio, the moisture and the suggested additions; the steps show the carbon and nitrogen totals.
The formula
Each material contributes its dry matter times its carbon or nitrogen content. With wet weight , moisture (%), carbon and nitrogen (% of dry matter), the Cornell Waste Management Institute formula is:
The moisture of the mix is . To reach a target ratio $R^*$ with a material carrying carbon and nitrogen per unit of wet weight, add
Water needed for a target moisture $M^$: $W = (M^ , Q_{\text{tot}} - W_{\text{mix}}) / (1 - M^*)$.
Worked example
Garden pile. 10 kg of grass clippings, 10 kg of leaves and 5 kg of food scraps contain 4.61 kg of carbon and 0.15 kg of nitrogen: a ratio of 29.9:1, right in the target range, at 61.8% moisture.
Manure pile. 100 kg of fresh cow manure on its own sits at only 19:1. Adding about 16.3 kg of straw brings it to 30:1 and lowers moisture from 81% to 71.3% — still wet, so turn the pile often or add a little more straw.
Why not average the ratios? Equal weights of grass (17:1) and sawdust (442:1) do not give 229.5:1 but 59:1: the wet grass holds far less dry matter than the sawdust, and the ratio must be computed from the summed carbon and nitrogen.
Typical values used by the calculator
| Material | %N (dry) | C:N | Moisture |
|---|---|---|---|
| Grass clippings | 3.4 | 17 | 82 % |
| Autumn leaves | 0.9 | 54 | 38 % |
| Straw | 0.7 | 80 | 12 % |
| Food scraps (kitchen waste) | 2.4 | 15 | 69 % |
| Vegetable trimmings | 2.7 | 19 | 87 % |
| Fruit waste | 1.4 | 40 | 80 % |
| Cow manure | 2.4 | 19 | 81 % |
| Horse manure | 1.6 | 30 | 72 % |
| Chicken manure | 8 | 6 | 69 % |
| Cardboard | 0.1 | 563 | 8 % |
| Sawdust | 0.11 | 442 | 39 % |
| Wood chips | 0.09 | 560 | 39 % |
Values are the typical or average figures of NRAES-54, Appendix A (wood-chip moisture is taken from sawdust, and sawdust nitrogen is set to match its C:N with about 49% carbon). Real materials vary widely — manure with bedding, wet versus dry leaves — so treat the result as a starting point and adjust by smell, temperature and feel.
Moisture: the other half of the recipe
Microbes need water as much as nitrogen. NRAES-54 gives 40–65% moisture as a workable range and 50–60% as the preferred one. A squeezed handful should feel like a wrung-out sponge: a few drops, no stream. Grass, food scraps and fresh manure are 70–90% water, so they also correct a dry pile; straw, cardboard and sawdust are dry and soak up excess water.
Frequently asked questions
What is the ideal C:N ratio for compost?
A starting mix of about 25 to 30 parts carbon to 1 part nitrogen by weight. Between 20 and 40 still composts, but more slowly or with more odour. Finished compost settles near 10 to 15:1.
What is the ratio of greens to browns?
There is no fixed volume rule, because materials differ so much. By weight, grass clippings and leaves in roughly equal amounts land near 30:1, while cardboard or sawdust need far less weight for the same carbon.
Why does my compost smell like ammonia?
The C:N ratio is too low: there is more nitrogen than the microbes can use, and the excess escapes as ammonia. Mix in leaves, straw, shredded cardboard or wood chips.
How do I find the carbon and nitrogen of a material?
Typical values are built in. For precise work, send a sample to a soil or compost lab and enter its %N, %C and moisture; carbon is often reported as organic matter, which is roughly 1.8 times the carbon.
Can I enter volumes instead of weights?
Only if you convert them: a bucket of grass weighs several times a bucket of dry leaves. Weigh one bucket of each material once, then multiply by the number of buckets.
Sources
- Cornell Waste Management Institute — Composting: C/N ratio calculation
- Cornell Waste Management Institute — Compost chemistry
- Rynk, R. (ed.), On-Farm Composting Handbook (NRAES-54), Appendix A, Table A.1
Last updated: