An ecosystem is formed by the interaction between a biological community and its physical environment. It includes all the living organisms in a given area, as well as the abiotic components like air, water, soil and minerals. Within an ecosystem, organisms interact with each other and their environment in ways that facilitate the transfer of energy and nutrients. There are two main types of ecosystems - aquatic ecosystems which are found in bodies of water, and terrestrial ecosystems found on land, including forests, grasslands, deserts and mountains. Each ecosystem contains producers, consumers and decomposers that interact to form a food web.