Composting works by providing the right conditions for organic material to decompose. This includes a mixture of green and brown materials, oxygen, and moisture. Over time, beneficial microorganisms break down the organic matter into finished compost.