Shrimp eat a variety of things, depending on their stage of growth and their environment. They are primarily scavengers, eating whatever they can find that is organic and small enough to fit in their mouths. Shrimp found in the wild and shrimp raised in home aquariums both have the same basic diet.
Life Cycle of a Shrimp
Shrimp spawn up to several miles offshore. Eggs are fertilized and sink to the bottom of the body of water. They start off as mite-like larvae, and float up to the surface of the water. They go through several larval stages over the next couple weeks, emerging as tiny versions of adult shrimp. They work their way back to the bottom of the ocean or tidal areas as they grow, eventually becoming scavengers crawling along the ocean floor.
What Young Shrimp Eat
Young shrimp in the larval stage are tiny and they float on the top of the water. The shrimp have little in the way of locomotion and are very small, so they eat other small things that are floating with them, mainly algae and plankton. The only difference between the diet of wild and farmed shrimp is plankton. Farmed and aquarium shrimp subsist mainly on algae and any plants that may have been planted to add some variety to their diet.
What Adult Shrimp Eat
Developed shrimp are scavengers, crawling on the ocean floor eating organic matter. Therefore, the diets of adult shrimp depend upon where the shrimp are located. Wild shrimp in the ocean eat plant matter, dead fish, clams, snails and crabs, worms and any other decaying organic matter they find. Farmed and aquarium shrimp find food the same way, but their habitats don't contain all of the different sources of food that the wild shrimp find. Farmed shrimp also are fed pellet food and brine shrimp. Shrimp also are cannibals, and will eat any other smaller shrimp they come across.
Shrimp don't hunt for "prey" in the manner most people would think of, stalking them like lions or luring them like angler fish, they just eat things they stir up while they're foraging. Live food mostly consists of worms and other shrimp. Since they stir up the muddy or sandy ocean bottom, shrimp don't look for food with their eyes, but rather smell it with the many feelers located on their heads.