The three main cycles of an ecosystem are the water cycle, the carbon cycle and the nitrogen cycle. These three cycles working in balance are responsible for carrying away waste materials and replenishing the ecosystem with the nutrients necessary to sustain life. If any of these three cycles should become unbalanced, the effects on the ecosystem can be catastrophic.
TL;DR (Too Long; Didn't Read)
There are a lot of things that come together to form a functioning ecosystem, but there are three cycles that are key to understanding the big picture: the water cycle, the carbon cycle and the nitrogen cycle.
The water cycle begins with precipitation. Water from lakes, rivers and oceans evaporates into the atmosphere. These water vapors gather, under the right conditions, to form clouds. Eventually, these vapors condense and become rain or another form of precipitation. This precipitation falls to the earth's surface. Next, some of the precipitation flows into the ground and becomes part of the ecosystem's water table. The rest flows into streams and rivers, and eventually back into the lakes and oceans from where it came. Along this journey, lifeforms in the ecosystem use the water to sustain life.
Carbon Cycle: Respiration
The carbon cycle can be broken into two smaller subcycles: respiration and photosynthesis. These subcycles are dependent upon one another. In the respiration cycle, fauna, or animal life inhabiting the biosphere, consume carbohydrates (in the form of plant life) and oxygen and output carbon dioxide, water and energy. The animals use the energy produced to power their biology.
Carbon Cycle: Photosynthesis
Flora, the ecosystem's plant life, perform photosynthesis. Plants take in energy from the sun, carbon dioxide and water and produce carbohydrates and oxygen. These carbohydrates and oxygen are readily used by the fauna present in the ecosystem. In addition to being consumed by animal life, some of these carbohydrates return to the earth when the flora die. There, they break down and the carbon returns to the ecosystem in the form of carbon dioxide. If not consumed by animals, carbon from decaying plants will eventually convert into fossil fuels.
Most of the nitrogen found in ecosystems exists as nitrogen gas. Nearly 78% of the earth's atmosphere is made of nitrogen. The nitrogen in the atmosphere is very stable and does not combine easily with other elements. Lightning has sufficient energy to convert nitrogen into nitrates, a form of nitrogen usable by plant life. The second way nitrogen is converted to nitrates is by nitrogen fixing bacteria. These bacteria use special enzymes to convert nitrogen to nitrates. Plants use these nitrates to form amino acids. Animals eat the plants for the amino acids to help build muscle tissue. When plants and animals die, denitrifying bacteria convert the nitrates back into the gaseous form of nitrogen, which is released back into the atmosphere.