They can't simply walk away. So, many sessile animals have motile larvae. Sessile animals, like sea anenomes, don't have to invest in complicated structures like legs or wings in order to move about and look for food. But being sessile limits them to one type of food source, the kind that just happens to float by. Sessile animals are usually filter feeders or suspension feeders.
Motile organisms are usually bilaterally symmetric , a group which includes most higher animals.
This is a much more efficient shape for moving through the environment. Animals in motion can actively seek out food and mates, and run away from predators. Animals in motion generally have a specific direction. And if you are moving forward, it makes good sense to concentrate your awareness of your environment in that direction. So bilaterally symmetric animals become cephalized .