As far as I understand, pressure acts downwards on a surface of a body in water because pressure $P$ is given by
$$ P = \frac{F}{A} = \frac{m \, g}{A} $$ where $F$ is the gravitational force on the body of mass $m$ with surface area $A$, and $g$ is the gravitational acceleration.
But I cannot see how pressure acts in all directions; namely, at the sides where apparently $F \neq mg$.
