If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Food chains & food webs

How food chains and food webs represent the flow of energy and matter. Trophic levels and efficiency of energy transfer.

Key points:

  • Producers, or autotrophs, make their own organic molecules. Consumers, or heterotrophs, get organic molecules by eating other organisms.
  • A food chain is a linear sequence of organisms through which nutrients and energy pass as one organism eats another.
  • In a food chain, each organism occupies a different trophic level, defined by how many energy transfers separate it from the basic input of the chain.
  • Food webs consist of many interconnected food chains and are more realistic representation of consumption relationships in ecosystems.
  • Energy transfer between trophic levels is inefficient—with a typical efficiency around 10%. This inefficiency limits the length of food chains.


Organisms of different species can interact in many ways. They can compete, or they can be symbionts—longterm partners with a close association. Or, of course, they can do what we so often see in nature programs: one of them can eat the other—chomp! That is, they can form one of the links in a food chain.
In ecology, a food chain is a series of organisms that eat one another so that energy and nutrients flow from one to the next. For example, if you had a hamburger for lunch, you might be part of a food chain that looks like this: grass cow human. But what if you had lettuce on your hamburger? In that case, you're also part of a food chain that looks like this: lettuce human.
As this example illustrates, we can't always fully describe what an organism—such as a human—eats with one linear pathway. For situations like the one above, we may want to use a food web that consists of many intersecting food chains and represents the different things an organism can eat and be eaten by.
In this article, we'll take a closer look at food chains and food webs to see how they represent the flow of energy and nutrients through ecosystems.

Autotrophs vs. heterotrophs

What basic strategies do organisms use to get food? Some organisms, called autotrophs, also known as self-feeders, can make their own food—that is, their own organic compounds—out of simple molecules like carbon dioxide. There are two basic types of autotrophs:
  • Photoautotrophs, such as plants, use energy from sunlight to make organic compounds—sugars—out of carbon dioxide in photosynthesis. Other examples of photoautotrophs include algae and cyanobacteria.
  • Chemoautotrophs use energy from chemicals to build organic compounds out of carbon dioxide or similar molecules. This is called chemosynthesis. For instance, there are hydrogen sulfide-oxidizing chemoautotrophic bacteria found in undersea vent communities where no light can reach.
Autotrophs are the foundation of every ecosystem on the planet. That may sound dramatic, but it's no exaggeration! Autotrophs form the base of food chains and food webs, and the energy they capture from light or chemicals sustains all the other organisms in the community. When we're talking about their role in food chains, we can call autotrophs producers.
Heterotrophs, also known as other-feeders, can't capture light or chemical energy to make their own food out of carbon dioxide. Humans are heterotrophs. Instead, heterotrophs get organic molecules by eating other organisms or their byproducts. Animals, fungi, and many bacteria are heterotrophs. When we talk about heterotrophs' role in food chains, we can call them consumers. As we'll see shortly, there are many different kinds of consumers with different ecological roles, from plant-eating insects to meat-eating animals to fungi that feed on debris and wastes.

Food chains

Now, we can take a look at how energy and nutrients move through a ecological community. Let's start by considering just a few who-eats-who relationships by looking at a food chain.
A food chain is a linear sequence of organisms through which nutrients and energy pass as one organism eats another. Let's look at the parts of a typical food chain, starting from the bottom—the producers—and moving upward.
  • At the base of the food chain lie the primary producers. The primary producers are autotrophs and are most often photosynthetic organisms such as plants, algae, or cyanobacteria.
  • The organisms that eat the primary producers are called primary consumers. Primary consumers are usually herbivores, plant-eaters, though they may be algae eaters or bacteria eaters.
  • The organisms that eat the primary consumers are called secondary consumers. Secondary consumers are generally meat-eaters—carnivores.
  • The organisms that eat the secondary consumers are called tertiary consumers. These are carnivore-eating carnivores, like eagles or big fish.
  • Some food chains have additional levels, such as quaternary consumers—carnivores that eat tertiary consumers. Organisms at the very top of a food chain are called apex consumers.
We can see examples of these levels in the diagram below. The green algae are primary producers that get eaten by mollusks—the primary consumers. The mollusks then become lunch for the slimy sculpin fish, a secondary consumer, which is itself eaten by a larger fish, the Chinook salmon—a tertiary consumer.
Image credit: Ecology of ecosystems: Figure 3 by OpenStax College, Biology, CC BY 4.0
Each of the categories above is called a trophic level, and it reflects how many transfers of energy and nutrients—how many consumption steps—separate an organism from the food chain's original energy source, such as light. As we’ll explore further below, assigning organisms to trophic levels isn't always clear-cut. For instance, humans are omnivores that can eat both plants and animals.


One other group of consumers deserves mention, although it does not always appear in drawings of food chains. This group consists of decomposers, organisms that break down dead organic material and wastes.
Decomposers are sometimes considered their own trophic level. As a group, they eat dead matter and waste products that come from organisms at various other trophic levels; for instance, they would happily consume decaying plant matter, the body of a half-eaten squirrel, or the remains of a deceased eagle. In a sense, the decomposer level runs parallel to the standard hierarchy of primary, secondary, and tertiary consumers.
Fungi and bacteria are the key decomposers in many ecosystems; they use the chemical energy in dead matter and wastes to fuel their metabolic processes. Other decomposers are detritivores—detritus eaters or debris eaters. These are usually multicellular animals such as earthworms, crabs, slugs, or vultures. They not only feed on dead organic matter but often fragment it as well, making it more available for bacterial or fungal decomposers.
Image credit: left, Decomposers by Courtney Celley/USFWS, CC BY 2.0; right, Earthworm by Luis Miguel Bugallo Sánchez, CC BY-SA 3.0
Decomposers as a group play a critical role in keeping ecosystems healthy. When they break down dead material and wastes, they release nutrients that can be recycled and used as building blocks by primary producers.

Food webs

Food chains give us a clear-cut picture of who eats whom. However, some problems come up when we try and use them to describe whole ecological communities.
For instance, an organism can sometimes eat multiple types of prey or be eaten by multiple predators, including ones at different trophic levels. This is what happens when you eat a hamburger patty! The cow is a primary consumer, and the lettuce leaf on the patty is a primary producer.
To represent these relationships more accurately, we can use a food web, a graph that shows all the trophic—eating-related—interactions between various species in an ecosystem. The diagram below shows an example of a food web from Lake Ontario. Primary producers are marked in green, primary consumers in orange, secondary consumers in blue, and tertiary consumers in purple.
Image credit: Ecology of ecosystems: Figure 5 by OpenStax College, Biology, CC BY 4.0; original work by NOAA, GLERL
In food webs, arrows point from an organism that is eaten to the organism that eats it. As the food web above shows, some species can eat organisms from more than one trophic level. For example, opossum shrimp eat both primary producers and primary consumers.
Bonus question: This food web contains the food chain we saw earlier in the article—green algae mollusks slimy sculpin salmon. Can you find it?

Grazing vs. detrital food webs

Food webs don't usually show decomposers—you might have noticed that the Lake Ontario food web above does not. Yet, all ecosystems need ways to recycle dead material and wastes. That means decomposers are indeed present, even if they don't get much air time.
For example, in the meadow ecosystem shown below, there is a grazing food web of plants and animals that provides inputs for a detrital food web of bacteria, fungi, and detritovores. The detrital web is shown in simplified form in the brown band across the bottom of the diagram. In reality, it would consist of various species linked by specific feeding interactions—that is, connected by arrows, as in the grazing food web aboveground. Detrital food webs can contribute energy to grazing food webs, as when a robin eats an earthworm.
Image credit: modified from Energy flow through ecosystems: Figure 5 by OpenStax College, Biology, CC BY 4.0; for complete credits of original images, please see pop-up below

Energy transfer efficiency limits food chain lengths

Energy is transferred between trophic levels when one organism eats another and gets the energy-rich molecules from its prey's body. However, these transfers are inefficient, and this inefficiency limits the length of food chains.
When energy enters a trophic level, some of it is stored as biomass, as part of organisms' bodies. This is the energy that's available to the next trophic level since only energy stored as biomass can get eaten. As a rule of thumb, only about 10% of the energy that's stored as biomass in one trophic level—per unit time—ends up stored as biomass in the next trophic level—per the same unit time. This 10% rule of energy transfer is a good thing to commit to memory.
As an example, let's suppose the primary producers of an ecosystem store 20,000 kcal/m2/year of energy as biomass. This is also the amount of energy per year that's made available to the primary consumers, which eat the primary producers. The 10% rule would predict that the primary consumers store only 2,000 kcal/m2/year of energy in their own bodies, making energy available to their predators—secondary consumers—at a lower rate.
This pattern of fractional transfer limits the length of food chains; after a certain number of trophic levels—generally three to six, there is too little energy flow to support a population at a higher level.
Image credit: modified from Ecological pyramid by CK-12 Foundation, CC BY-NC 3.0
Why does so much energy exit the food web between one trophic level and the next? Here are a few of the main reasons for inefficient energy transfer1,2:
  • In each trophic level, a significant amount of energy is dissipated as heat as organisms carry out cellular respiration and go about their daily lives.
  • Some of the organic molecules an organism eats cannot be digested and leave the body as feces, poop, rather than being used.
  • Not all of the individual organisms in a trophic level will get eaten by organisms in the next level up. Some instead die without being eaten.
The feces and uneaten, dead organisms become food for decomposers, who metabolize them and convert their energy to heat through cellular respiration. So, none of the energy actually disappears—it all winds up as heat in the end.

Want to join the conversation?