Worms move by using their longitudinal muscles, circular muscles and setae. Setae are small hairs that protrude from each segment of the worm's body. Worms can extend these hairs into the surrounding dirt in order to anchor one segment of itself while it pulls the rest of its body forward.
The worm's longitudinal muscles run the length of its body and allows the animal to contract or stretch itself out. The circular muscles are found in each of the 100 to 150 segments of a worm and are used to lengthen or shorten its individual segments independently from one another. Worms would not be able to move if each segment was unable to be operated independently.
Worms are classified into the Annelida phylum of organisms because of the ringed segments that make up their bodies. A worm propels itself forward and backward by using these muscles and setae in tandem with one another. As worms move through dirt, they construct a network of tunnels that aerates and saturates the soil with water and other nutrients. Worms eat dead and decaying organics that are found throughout the soil as they burrow. They break down these organic nutrients and dispel them in a type of nutrient-rich fertilizer, also known as worm castings.