Orbital Period Calculator
Solar System Presets
Exoplanet Presets
Mean orbital distance from the central body. 1 AU = Earth–Sun distance.
Mass of the star, planet, or body being orbited. 1 solar mass = 1 M☉.
0 = circular, 0–1 = elliptical. Used to compute apoapsis and periapsis distances.
Enter Orbital Parameters
Select a calculation mode, choose a preset or enter values manually, and see the orbital period, velocity, circumference, and a solar system comparison instantly.
How to Use the Orbital Period Calculator
Choose a Calculation Mode
Click one of the three mode buttons at the top: 'Solve for Period' (enter distance and mass to find how long one orbit takes), 'Solve for Distance' (enter period and mass to find orbital radius), or 'Solve for Mass' (enter distance and period to determine the central body's mass — useful for measuring star masses from exoplanet data).
Load a Preset or Enter Values
Click any planet button (Mercury through Neptune) to auto-fill the solar system values, or click an exoplanet preset (51 Peg b, TRAPPIST-1b, Proxima Cen b, or Kepler-452b) to load a famous exoplanet scenario. For a custom object, type the semi-major axis and choose your preferred unit (AU, km, meters, miles, or light-years). Set the central body mass in solar masses, Earth masses, or kilograms.
Review All Outputs
Results appear instantly and update as you type. The hero section shows the primary answer, followed by the period in all time units (years, days, hours, seconds), distance in AU and km, mean orbital velocity in km/s, and orbital circumference. Enter an eccentricity value between 0 and 1 to also see the apoapsis and periapsis distances. The solar system bar chart shows where your orbit falls relative to all eight planets.
Export or Print
Click 'Export CSV' to download a spreadsheet of all computed values for use in reports, presentations, or data analysis. Click 'Print Results' to generate a clean print layout. For two-body precision, click 'Advanced options' to add the orbiting body mass and see the full Newton-Kepler calculation with the gravitational parameter μ = GM.
Frequently Asked Questions
What is the difference between Kepler's original formula and Newton's generalized version?
Kepler's original Third Law, T² = a³, works only when the time is measured in Earth years and the distance in Astronomical Units, and it implicitly assumes the central body is the Sun. It cannot handle any other star or any unit system. Newton's generalized version, T² = 4π²a³ / [G(M+m)], is universal: it works for any central body of any mass, in any unit system, and even accounts for the mass of the orbiting body when it is non-negligible (such as in a binary star system). This calculator uses Newton's version so it correctly handles exoplanets around low-mass stars like TRAPPIST-1 and binary systems.
Why is the planet's own mass usually ignored?
In Kepler's Third Law, the formula contains (M+m) — the sum of both bodies' masses. For a planet orbiting a star, the star's mass dominates overwhelmingly. The Sun is about 1,048 times more massive than Jupiter, and more than 330,000 times more massive than Earth. Ignoring the planet's mass introduces an error of less than 0.1% for Jupiter and less than 0.0003% for Earth. This negligible difference is why most educational tools and even many research papers use M+m ≈ M. Our advanced mode lets you include planet mass for full precision.
How do astronomers use orbital periods to measure star masses?
By rearranging Kepler's Third Law to M = (4π²a³) / (GT²) − m, astronomers can compute a star's mass if they know the orbital period and semi-major axis of a planet orbiting it. For exoplanets detected by the transit method, the period is measured directly from the timing of brightness dips. The semi-major axis can be inferred from the period and an estimate of the star's temperature and luminosity. This technique has produced mass measurements for thousands of stars and is one of the primary tools of exoplanet science. Use the 'Solve for Mass' mode to explore this yourself.
What does orbital eccentricity affect?
Eccentricity (e) describes how elongated an orbit is. A circle has e = 0; a highly stretched ellipse approaches e = 1. For Kepler's Third Law, the period depends only on the semi-major axis — not on eccentricity — so two orbits with the same semi-major axis but different eccentricities have identical periods. However, eccentricity does determine the range of distances: apoapsis (farthest point) = a(1+e) and periapsis (closest point) = a(1−e). Earth's eccentricity of 0.0167 means its distance from the Sun varies by about ±1.7% over the year. Mercury's high eccentricity of 0.2056 causes a 38% variation in its Sun distance.
What is the gravitational parameter μ and why is it useful?
The standard gravitational parameter μ = GM combines the gravitational constant G with the central body mass M into a single number. It is far more precisely known for bodies in our solar system than either G or M individually, because it can be measured directly from spacecraft trajectory data. For the Sun, μ☉ = 1.327×10¹¹ km³/s². For Earth, μ⊕ = 3.986×10⁵ km³/s². Using μ directly avoids introducing error from the less-precisely-known value of G. This quantity appears in all real spacecraft trajectory software and is the natural unit of orbital mechanics.
Why does the orbital visualization use a logarithmic scale?
The solar system spans an enormous range of distances — from Mercury at 0.387 AU to Neptune at 30.07 AU, a factor of about 78. If the diagram used a linear scale, Mercury's orbit ring would be invisible while Neptune's would dominate the screen. A logarithmic scale compresses large ranges so that orbits separated by a factor of 10 appear as equal visual steps, making all planets simultaneously visible in the same diagram. This is the same reason orbital period bar charts in astronomy textbooks often use a log scale. The visualization is approximate and intended for relative comparison, not precise measurement.