Compost not working? Fix a smelly, slimy, slow or fly-filled heap

Almost every compost problem comes down to two things: how wet the heap is and how much air gets in. A heap that smells, turns to slime or sits there doing nothing can nearly always be fixed in an afternoon with a pile of torn cardboard, a fork and, sometimes, a watering can. If you are just getting set up, start with the basics of greens, browns and choosing a bin; this guide is for when the heap is already going and something feels off.
Do the squeeze test first
Before you change anything, put on a glove and squeeze a handful from the middle of the heap, not the top.

Water running out means it is too wet. A handful that falls apart as soon as you open your hand is too dry. You want the feel of a wrung-out sponge: it holds its shape and gives up a drop or two at most. That one check tells you which half of this guide you need.
It smells rotten, sour or slimy
A rotten-egg or sour smell means the heap is too wet and short of air. The microbes that break things down cleanly need oxygen; when water fills the gaps, other microbes take over and they are the smelly ones.
The usual causes:
- Too many greens. Kitchen scraps are mostly water, and a bin fed only peelings and coffee grounds slumps into sludge.
- Thick layers of grass clippings. Fresh clippings mat into a dense, airless layer within days.
- Rain getting in, or a bin with no lid sitting in a wet corner.
The fix is the same every time. Tear up plain brown cardboard, egg boxes or paper, or grab dry leaves, and fork them through the wet layer rather than piling them on top. Be generous: for a really soggy bin you may need as much dry material again as there is wet. Turn the heap while you are there so air gets back into the middle. From then on, add a handful of browns every time you tip in the kitchen caddy, and mix grass clippings in thin layers.
It smells of ammonia
A sharp, ammonia smell, like a cat litter tray, means too much nitrogen. It happens most after a big load of grass clippings. It is the same fix as above: mix in browns. That smell is nitrogen escaping into the air, nitrogen you would rather keep in the compost.
Nothing seems to be happening
If the scraps you added a month ago still look like scraps, check these in order:
- Too dry. Do the squeeze test. A dry heap barely rots. Water it as you turn it, a can at a time, until the middle feels damp.
- Too many browns. A bin of mostly cardboard and dry leaves has little to feed the microbes. Add greens: kitchen scraps, coffee grounds, fresh grass.
- Pieces too big. Whole cabbage stalks, corn cobs and thick prunings take a long time. Chop or snap them smaller.
- Cold weather. Everything slows down in winter, and small heaps lose heat fastest. This is normal. Keep adding scraps; the heap will pick up again in spring.
Ants nesting in the heap are another sign it is too dry.
Fruit flies or other flies
Small flies come for fresh food left on the surface. Bury new scraps a little way into the heap, or cover each load with a layer of browns or finished compost, and keep the lid on. In a kitchen caddy, emptying it every couple of days does more than any trap.
Rats or mice
Rodents look for food and for a warm, quiet place to nest. Make the heap less inviting:
- Keep cooked food, meat, fish, dairy and bread out of an open home bin.
- Turn or disturb the heap often, since rodents prefer to nest somewhere left alone.
- Stand the bin on fine wire mesh or a solid base so nothing can dig in from below, and keep it moist, because a dry heap makes a comfortable nest.
Things that just won't rot
Some things are slow, and some never belonged there:
- Avocado stones, peach stones and nutshells break down very slowly. Smash them or leave them out.
- Eggshells come out looking much the same unless crushed. They do no harm, so crush them and stop worrying.
- Tea bags may leave a mesh skeleton behind, because many are sealed with plastic. Tear them open and compost the leaves, or pick the mesh out when you use the compost.
- Packaging labelled "compostable" is often made for industrial composting, which runs much hotter than a garden bin. Unless it says home compostable, it may sit in your heap for years.
- Woody stems and old jack-o'-lanterns are fine but bulky. Chop them first, as in using up the whole pumpkin.
Using compost that's nearly ready
You don't have to wait for the whole bin to finish. The compost at the bottom is usually done first: dark, crumbly and smelling of soil. Dig it out, throw any lumps that haven't rotted back in the top, and use the rest on beds or pots.
One good way to send less in the first place: simmer vegetable peelings into stock before they go in. Soft, cooked-down scraps rot faster too.