Kepler's Third Law Calculator
- In solar-system units Kepler's third law is T^2 = a^3 / M, because the constants G and 4 pi^2 cancel against the Earth-Sun calibration.
- T = sqrt(a^3 / M) = sqrt(5.200^3 / 1.000) = sqrt(140.6080) = 11.86 years.
- That is about 4,331 days per orbit, on an orbit with a semi-major axis of 777,908,928 km.
- The law cares only about the semi-major axis and the central mass — the orbit's eccentricity and the orbiting body's own mass (when it is comparatively tiny) do not enter.
This Kepler's third law calculator applies the rule that the square of the orbital period is proportional to the cube of the semi-major axis. In solar-system units the law is exact and constant-free: T^2 = a^3 / M. Enter the semi-major axis (a) in AU and the central mass (M) in solar masses, and the calculator returns the orbital period (T) in years — or enter the period and mass to solve for the semi-major axis instead. For example, Jupiter at 5.2 AU from the Sun gives T = 11.86 years (about 4,331 days), its known period; Mars at 1.524 AU gives 1.88 years, matching its observed period; and an 8-year period around a 2-solar-mass star implies a semi-major axis of 5.04 AU.
Kepler's third law depends only on the semi-major axis and the central mass — eccentricity and the orbiting body's own mass (when comparatively tiny) do not enter. Newton's form of the law, with G and the total mass, is how astronomers weigh stars, planets and black holes from orbits, making it the accepted standard for this kind of calculation. This page shows the formula, step-by-step workings, worked examples and sources so you can follow every result the calculator produces.
Worked examples
Jupiter around the Sun
Primary result: 11.86 years — Jupiter's 5.2 AU orbit takes 11.86 years. (Period from axis and mass · 5.2 · 1 · 1)
| Kepler's third law | 11.86 years |
| Orbital period in days | 4,331 |
| Semi-major axis in km | 777,908,928 |
Mars around the Sun
Primary result: 1.88 years — Mars at 1.524 AU matches its known 1.88-year period. (Period from axis and mass · 1.524 · 1 · 1)
| Kepler's third law | 1.88 years |
| Orbital period in days | 687 |
| Semi-major axis in km | 227,987,155 |
An 8-year orbit of a 2-solar-mass star
Primary result: 5.04 AU — solving backwards: an 8-year period around a heavier star sits at 5.04 AU. (Axis from period and mass · 1 · 2 · 8)
| Kepler's third law | 5.04 AU |
| Semi-major axis in km | 753,926,025 |
| Orbital period in days | 2,922 |
Kepler's third law formula
Kepler's third law states that the square of the orbital period is proportional to the cube of the semi-major axis. When you work in solar-system units — years for the period, astronomical units (AU) for the semi-major axis, and solar masses for the central mass — the formula is exact and constant-free: T^2 = a^3 / M. The reason no gravitational constant appears is that the units are calibrated against the Earth-Sun system. Earth orbits the Sun in 1 year at 1 AU around 1 solar mass, so the proportionality constant is exactly 1 and cancels out. This makes a kepler's third law calculator especially convenient for quick solar-system work.
The law depends only on the semi-major axis and the central mass. Eccentricity does not enter the formula, and the orbiting body's own mass does not appear when it is comparatively tiny — which is why a planet's mass is irrelevant in the basic version. You can verify the formula with familiar examples. Jupiter at 5.2 AU from the Sun gives T = 11.86 years (about 4,331 days), its known period. Mars at 1.524 AU gives 1.88 years, matching its observed period. Going the other direction, an 8-year period around a 2-solar-mass star implies a semi-major axis of 5.04 AU.
Newton generalized the law by restoring the gravitational constant G and using the total mass of the two bodies rather than the central mass alone. Newton's form of the law, with G and the total mass, is how astronomers weigh stars, planets and black holes from orbits. When the orbiting body is much less massive than what it orbits, the total mass is essentially the central mass, and the simple solar-system formula above remains an excellent approximation.
Worked examples
The three cases below show how a Kepler's third law calculator handles both directions: solving for the orbital period when you know the semi-major axis, and solving backwards for the semi-major axis when you know the period. In solar-system units, where distance is measured in astronomical units (AU), time in years, and mass in solar masses, the law is exact and constant-free: T^2 = a^3 / M. That means you can plug in values directly without worrying about constants like G.
Start with Jupiter, which orbits at 5.2 AU from the Sun. With M = 1 solar mass, the equation gives T^2 = 5.2^3 / 1 = 140.608, so T = 11.86 years. That result matches Jupiter's known period of about 4,331 days. Mars provides a second check: at 1.524 AU, the same calculation gives T^2 = 1.524^3 = 3.5396, so T = 1.88 years, matching its observed period. In both cases the orbiting body's own mass is comparatively tiny and does not enter the result — only the semi-major axis and the central mass matter.
The third example reverses the direction. Suppose a planet has an 8-year period around a 2-solar-mass star. Rearranging the law gives a^3 = T^2 × M = 64 × 2 = 128, so a = 5.04 AU. This is the kind of backward calculation astronomers use when they observe a period and need the orbital size. The same logic scales up to Newton's form of the law, which includes G and the total mass; that broader version is how astronomers weigh stars, planets, and black holes from orbits.
Notice that eccentricity never appears in any of these calculations. A long, thin ellipse and a nearly circular orbit with the same semi-major axis produce the same period, provided the central mass is the same. That property is what makes the law so useful for quick estimates and for checking whether an observed orbit is consistent with a given central body.
| Body or scenario | Semi-major axis (AU) | Central mass (solar masses) | Period (years) |
|---|---|---|---|
| Jupiter | 5.2 | 1 | 11.86 |
| Mars | 1.524 | 1 | 1.88 |
| Hypothetical planet | 5.04 | 2 | 8 |
Solving for period vs solving for distance
Kepler's third law works in two directions. You can start with a known distance and solve for the orbital period, or you can start with a known period and solve for the semi-major axis. A kepler's third law calculator handles both cases, and the direction you choose depends on the problem at hand. In solar-system units the law is exact and constant-free: T^2 = a^3 / M, where T is the period in years, a is the semi-major axis in astronomical units (AU), and M is the central mass in solar masses.
Solving for period is the classic ephemeris problem. When you know where a body orbits and want to know how long it takes, you plug in the semi-major axis and the central mass. Jupiter at 5.2 AU from the Sun gives T = 11.86 years, which is about 4,331 days — its known period. Mars at 1.524 AU gives 1.88 years, matching its observed period. This direction is used for predicting future positions, building tables of orbital motion, and checking that a measured distance is consistent with a measured period.
Solving for distance is the classic orbit-fitting problem. When you observe how long something takes to orbit — say, a transiting exoplanet crossing its star every 8 years — and you want to know how far it sits from that star, you rearrange the law. An 8-year period around a 2-solar-mass star implies a semi-major axis of 5.04 AU. This is the direction astronomers use for exoplanet orbit fitting: the period comes straight from transit or radial-velocity timing, and the central mass comes from the star's spectral type, so the semi-major axis falls out of the calculation.
The law depends only on the semi-major axis and the central mass. Eccentricity and the orbiting body's own mass, when comparatively tiny, do not enter. For cases where the orbiting body is not negligible — two stars of similar mass, for example — Newton's form of the law, with G and the total mass, takes over. That general form is how astronomers weigh stars, planets, and black holes from observed orbits.
What Kepler's third law ignores
A kepler's third law calculator is a powerful tool, but it rests on simplifications that break down in certain astrophysical settings. The law depends only on the semi-major axis and the central mass — eccentricity and the orbiting body's own mass (when comparatively tiny) do not enter. That is a safe assumption for planets in our solar system, where the Sun dominates overwhelmingly, and it is why the constant-free form T^2 = a^3 / M works so cleanly in solar-system units. The worked examples confirm this: Jupiter at 5.2 AU from the Sun gives T = 11.86 years (about 4,331 days), matching its known period, and Mars at 1.524 AU gives 1.88 years, matching its observed period.
Eccentricity is the first simplification. Kepler's third law uses the semi-major axis, which is the average orbital distance, and treats the orbit as if shape does not matter. For nearly circular orbits like those of most planets, that is fine. For highly elliptical orbits, the period still comes out correct because the semi-major axis captures the right average, but the law says nothing about how the object's speed varies along that orbit. If you need to know where a body is at a given time or how fast it moves at perihelion versus aphelion, the third law alone will not get you there.
The orbiting body's own mass is the second omission. When the companion is tiny compared with the central object — Earth relative to the Sun, or a moon relative to its planet — ignoring it changes the result by a negligible fraction. In binary star systems, though, neither star is negligible. Two stars of comparable mass both orbit their common center of mass, and the simple form of the law no longer holds. Newton's form of the law, with G and the total mass, is how astronomers weigh stars, planets and black holes from orbits. By using the combined mass instead of just the central mass, Newton's version restores accuracy where the original law would miss the mark.
Relativistic corrections are the third factor, and they matter most for close exoplanets and compact objects. A hot Jupiter whipping around its star every few days, or a star orbiting close to a black hole, moves through strong gravitational fields where Newtonian gravity and Kepler's laws begin to lose precision. General relativity introduces effects such as periapsis precession that the classical law cannot describe. For the 8-year orbit around a 2-solar-mass star that implies a semi-major axis of 5.04 AU, none of this matters — the orbit is wide enough and the speeds gentle enough that the classical result stands. But the regime where omissions start to matter is real, and knowing where that line falls is part of using the calculator well.
FAQs
How do you use Kepler's third law?
Use years, AU, and solar masses with the formula T = sqrt(a^3 / M). For example, Jupiter orbiting at a = 5.2 AU around a 1-solar-mass Sun gives sqrt(140.6) = 11.86 years. This lets you calculate the orbital period directly when you know the distance and the central star's mass.
What is Kepler's third law in simple terms?
Planets farther from their star take disproportionately longer to orbit. If you double the distance, the period grows by 2^(3/2), about 2.83 times. This means the orbital period rises faster than the distance, so outer planets have much longer years than inner ones.
Does the planet's mass affect its orbital period?
Almost not at all when the planet is much lighter than the star. The law uses the central mass, so a small planet's mass is negligible. Newton's full form uses the sum of both masses, but for most planets the difference is tiny enough to ignore.
Can Kepler's third law find a planet's distance?
Yes. Measure the period and invert the law using a = (T^2 M)^(1/3). For example, an 8-year period around a 2-solar-mass star gives 5.04 AU. This is how astronomers determine a planet's distance when they can observe how long it takes to complete one orbit.
Why is the law exact in AU and years?
Those units are defined by Earth's own orbit: 1 AU, 1 year, and 1 solar mass. Because of this, G and 4 pi^2 cancel out of the equation, leaving a simple relationship. This makes calculations straightforward when you work in astronomical units, years, and solar masses.
Does eccentricity change the period?
No. Only the semi-major axis matters. A circular orbit and a highly elliptical orbit with the same semi-major axis have the same period. Eccentricity changes the shape of the path and the speed at different points, but it does not change how long one full orbit takes.