What is the critical factor determining the direction in which a comet's tails always point?

Answer

Away from the Sun

The tails are formed by solar wind and sunlight pressure pushing material away from the Sun. Therefore, they always point away from the Sun, regardless of the comet's direction of motion along its orbit.

What is the critical factor determining the direction in which a comet's tails always point?
Spaceastronomysolar systemcometparts