Yes, all of the planets and nearly all asteroids orbit in the same direction (anticlockwise if you were looking down on the Solar System from way above the Earth’s north pole) – and they all orbit close to the same flat plane as well. This is because they, along with the Sun itself, all formed from the same protoplanetary nebula – a cloud of interstellar gas and dust that began to collapse under its own gravity around 5 billion years ago.
As the nebula became more concentrated, it flattened out and began to spin more quickly, and the Sun, asteroids and planets then condensed out of different parts of this flattened disc. The few objects that follow backward, or retrograde, orbits – and those whose orbits are sharply tilted to the lane of the Solar System – tend to be the result of close encounters with the disruptive gravity of a giant body like Jupiter.
Answered by Giles Sparrow