The flow of energy is unidirectional in the food chain due to two reasons.
A predator always eats its prey but the other way round is not possible.
Moreover, out of the total energy consumed by an organism at a particular trophic level, 90% is utilised for its own need and just 10% is left for the organism of next trophic level. Thus, the availability of energy gets reduced at each subsequent trophic level. Due to this, the flow of energy is unidirectional in a food chain.