The force that keeps planets in orbit around the sun is gravity. Gravity is the fundamental force of attraction between objects with mass. In the case of the solar system, the sun's massive gravitational pull keeps the planets in their respective orbits. The gravitational force between the sun and each planet acts as a centripetal force, continuously pulling the planet toward the sun and keeping it in its elliptical path. This gravitational force balances the planet's inertia, resulting in a stable orbit around the sun.