An ecosystem is a system made up of both living and nonliving parts that work together as a unit. Open systems receive inputs from outside the system, like a terrarium receiving energy from the sun. Very few systems are truly closed, as most receive inputs and produce outputs. An ecosystem contains populations of different species that live in a community and depend on each other to survive. Both living things like plants and animals, and nonliving things like sunlight, air, water and soil are important parts of an ecosystem.