We know according to Newton’s first law of motion that an object in motion tends to stay in motion unless acted upon by an outside force.This law means that any object, unless acted upon by an outside force, will travel in a straight line. This is what happens with the planets; they would move in a straight line but are acted upon by gravity.
The reason the Earth moves in an elliptical orbit is a combination of the Earth's tendency to follow a straight path as it speeds through space and sun's gravitational pull. The Earth moves at a rate of 68,400 miles an hour! The diagram above shows this.