The gravitational attraction of the sun provides the necessary centripetal force to all the planets for their orbital motion around the sun. Due to which all the planets revolves around the sun. However, the path of all the planets and satellites are elliptical with sun at a focus.
According to Kepler's first law, circular path is a special case of an ellipse when the major and minor axes are equal. For a circular path, the planet should have velocity perpendicular to the line joining it with the sun and the magnitude should satisfy the equation . If these conditions are not satisfied, the planets move in an ellipse.