Newton's Law of Universal Gravitation Calculator

Gravitational force formula F = Gm₁m₂/r² (Newton's law of universal gravitation). Calculate the force between two masses, or solve for a mass or distance. G = 6.674 × 10⁻¹¹ N·m²/kg².

Last updated 28 November 2026

ResultEnter values to calculate
    Show calculation steps

    What is Newton's law of universal gravitation?

    Newton's Law of Universal Gravitation: Every mass attracts every other mass with a force proportional to the product of their masses and inversely proportional to the square of the distance between their centres. — Isaac Newton, 1687

    Why does an apple fall to the ground, and why does the Moon circle the Earth instead of flying off into space? Isaac Newton's great insight was that these are the same thing. The force pulling the apple down is the same force bending the Moon's path into an orbit. In the Principia (1687), he proposed that every mass in the universe attracts every other mass, with a force given by:

    F = G m₁m₂ / r²
    • More mass, more pull. The force is proportional to the product of the two masses.
    • Inverse square. Double the distance between the centres and the force drops to a quarter.
    • Always attractive. Unlike electric charge, there is no "negative mass" that would make gravity repel.

    The gravitational constant G is tiny: 6.6743 × 10⁻¹¹ N·m²/kg². That is why you do not feel pulled towards the people or buildings around you. Gravity only becomes noticeable when at least one object is enormous, like a planet or a star. G was first measured in 1798 by Henry Cavendish. He used a torsion balance to detect the minute attraction between lead spheres, and from it he calculated the density of the Earth.

    The formula explained

    F = G m1 m2r²
    SymbolQuantitySI unitMeaning
    FGravitational forceNAttractive gravitational force
    m₁Mass 1kgFirst mass
    m₂Mass 2kgSecond mass
    rDistance between centersmDistance between centres of mass

    Units. Masses in kilograms, distance in metres and force in newtons, with G = 6.6743 × 10⁻¹¹ N·m²/kg² (CODATA 2018).

    r is centre to centre. For planets and stars, measure from the centre of each body, not from its surface. A satellite 400 km above Earth is r = 6371 + 400 = 6771 km from Earth's centre.

    Spheres act like points. Newton proved that a uniform sphere attracts objects outside it as if all its mass were at its centre. That is why the simple formula works for planets.

    Surface gravity. At a planet's surface, the force on a mass m is mg, so g = GM/R². For Earth, g = 6.6743 × 10⁻¹¹ × 5.972 × 10²⁴ / (6.371 × 10⁶)² ≈ 9.82 m/s².

    Equal and opposite. The Earth pulls the Moon exactly as hard as the Moon pulls the Earth, by Newton's third law. The Moon accelerates much more only because it has much less mass.

    How to use this calculator

    1. Choose the quantity you want to find in the Calculate menu. It is highlighted as the result field.
    2. Enter the known values. Scientific notation such as 1.6e-11 is accepted.
    3. Select a unit for each value. Units are converted to SI automatically.
    4. The answer updates as you type. Open Show calculation steps to see the working, or use Copy result to share a link with your inputs.

    Step-by-step worked example

    Problem. (a) Find the gravitational force between the Earth (5.972 × 10²⁴ kg) and the Moon (7.348 × 10²² kg), 384 400 km apart. (b) What is g at the height of the International Space Station, 400 km up? (c) How strongly do two 70 kg people 1 m apart attract each other?

    Part (a)

    1. Convert. r = 3.844 × 10⁸ m.
    2. Substitute. F = 6.6743 × 10⁻¹¹ × 5.972 × 10²⁴ × 7.348 × 10²² / (3.844 × 10⁸)².
    3. F = 1.98 × 10²⁰ N. This force keeps the Moon in orbit and raises the tides.

    Part (b)

    1. Distance from Earth's centre. r = 6.771 × 10⁶ m.
    2. g = GM/r² = 6.6743 × 10⁻¹¹ × 5.972 × 10²⁴ / (6.771 × 10⁶)² = 8.7 m/s², about 89% of its surface value.
    3. Astronauts float not because gravity is absent, but because they and the station are falling around the Earth together, in continuous free fall.

    Part (c)

    1. F = 6.6743 × 10⁻¹¹ × 70 × 70 / 1² = 3.3 × 10⁻⁷ N, about the weight of a few grains of fine sand. Far too small to notice.

    Try it: the calculator's defaults reproduce part (a).

    How to interpret the result

    • Compare with weight. Dividing the force by the smaller mass gives the gravitational acceleration it feels. For the Moon in part (a), that is 1.98 × 10²⁰ / 7.348 × 10²² ≈ 0.0027 m/s². That is exactly the acceleration needed to keep it on its circular path, as Newton himself checked.
    • Inverse-square scaling. Going from Earth's surface to twice Earth's radius from the centre reduces gravity to a quarter. It never truly reaches zero.
    • Gravity is weak but cumulative. Every particle in a planet pulls in the same direction, and there is no cancelling negative mass. So gravity dominates on large scales even though it is negligible between atoms.
    • Know the limits. Newton's law is extremely accurate for most purposes, including spaceflight. Very strong fields and very precise measurements need Einstein's general relativity.

    Real-world applications

    • Spaceflight. Satellite orbits, rocket launches and interplanetary missions are planned with Newton's law, with small relativistic corrections where needed.
    • Weighing planets and stars. Measuring a moon's orbit around a planet gives the planet's mass directly. This is how the masses of Jupiter, the Sun and distant stars with orbiting planets are known.
    • Tides. The Moon's pull is slightly stronger on the side of the Earth facing it than on the far side. This difference raises the ocean tides, with a smaller contribution from the Sun.
    • Discovering Neptune. In 1846, irregularities in Uranus's orbit led Urbain Le Verrier and John Couch Adams to predict an unseen planet. Neptune was found almost exactly where Le Verrier calculated.
    • Geophysics. Tiny variations in gravity measured at the surface reveal dense ore bodies, oil-bearing structures and changes in ice and groundwater. Satellite missions such as GRACE map these changes from orbit.

    Common mistakes and unit-conversion tips

    1. Distance in km. 384 400 km must become 3.844 × 10⁸ m. The calculator converts km for you.
    2. Measuring from the surface. For a satellite, add the planet's radius to the altitude.
    3. Forgetting to square r. This is the most common slip in gravity problems.
    4. Thinking astronauts are beyond gravity. At ISS altitude, gravity is still about 89% as strong as on the ground. Weightlessness is free fall.
    5. Mixing up G and g. G is the universal constant, 6.6743 × 10⁻¹¹ N·m²/kg². g is the local acceleration, about 9.81 m/s² on Earth.

    Frequently asked questions

    What is the gravitational force equation?

    F = G · m₁ · m₂ / r², where G = 6.6743 × 10⁻¹¹ N·m²/kg², m₁ and m₂ are the masses in kg and r is the distance between their centres in metres. Near the Earth's surface this simplifies to F = mg with g ≈ 9.81 m/s².

    Why don't I feel attracted to other people?

    Two 70 kg people 1 m apart attract each other with about 3 × 10⁻⁷ N, far too small to notice.

    When is Newtonian gravity not enough?

    In very strong fields or for very precise measurements (black holes, GPS timing, Mercury's orbit), you need general relativity.

    What is the difference between G and g?

    G is the universal gravitational constant, the same everywhere: 6.6743 × 10⁻¹¹ N·m²/kg². g is the gravitational acceleration at a particular place. It is about 9.81 m/s² at Earth's surface and depends on the planet's mass and radius, g = GM/R².

    How does gravity change with altitude?

    It follows the inverse-square law measured from Earth's centre: g(h) = g₀ × (R/(R + h))². At 400 km it is about 89% of the surface value; at the Moon's distance, about 0.03%.

    Sources and further reading

    1. Newton, I. (1687). Philosophiæ Naturalis Principia Mathematica. London: Royal Society. Book III.
    2. Cavendish, H. (1798). Experiments to determine the density of the Earth. Philosophical Transactions of the Royal Society of London, 88, 469–526.
    3. National Institute of Standards and Technology. CODATA value: Newtonian constant of gravitation. physics.nist.gov.
    4. Halliday, D., Resnick, R., & Walker, J. (2018). Fundamentals of Physics (11th ed.). Wiley. Chapter 13, Gravitation.