Physics calculator

Potential Energy Calculator

Calculate gravitational potential energy or ideal spring potential energy, with rearranged height mode for gravitational cases.

Last reviewed: July 21, 2026Physics mechanics engine v1.0.0

Physics calculator

Potential Energy Calculator

Enter values, select units and calculate locally. Results use SI internally and show rounded display values.

Decimal.js physics math

Mode

Find gravitational potential energy from mass, gravity and height.

Gravitational inputs

Result and visual stay hidden until you choose Calculate.

Formula and assumptions

Primary formula

PE = m x g x h; spring PE = 1/2 x k x x^2.

Input assumptions

Gravity is constant. Spring mode assumes Hooke's-law behavior. Mass and spring constant must be greater than zero.

Precision note

Physics Phase 1 converts compatible inputs into SI units before calculating. Decimal.js is used for arithmetic where practical; trigonometric angle factors are rounded for display.

Physics calculation flow

Parse

Read labelled inputs, selected units and calculation mode from the calculator card.

Convert

Convert compatible values to SI base or derived units without calling external services.

Calculate

Apply the selected deterministic mechanics formula and validate against NaN, Infinity and invalid divisors.

Label

Display the result, supporting unit rows, formula steps, warnings and dynamic visual below the input card.

What Potential Energy Calculator does

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring.

The calculator is deterministic and runs from manual inputs only. It is a physics formula tool, so it should not be confused with a unit converter that only changes labels after a value is already known.

Formula and variables

PE = m x g x h; spring PE = 1/2 x k x x^2.

The calculator converts supported units into SI base or derived units for the actual calculation, then formats the result in the selected display unit.

  • m is mass
  • g is gravity
  • h is height
  • k is spring constant
  • x is spring displacement

Worked examples

Use the examples below to check expected order of operations and unit handling before applying the tool to your own values.

  • 10 kg x 9.80665 m/s^2 x 5 m = 490.3325 J
  • 0.5 x 100 N/m x (0.2 m)^2 = 2 J
  • 981 J / (10 kg x 9.80665 m/s^2) = about 10.0033 m

Unit conversions

Length, time, mass, speed, force, energy and power units reuse the central NexaCalc conversion registry. Acceleration and spring-constant units use the same SI-first convention for mechanics formulas.

The displayed conversion rows are supporting context. They do not change the physical assumptions of the selected formula.

Common mistakes

Most errors come from mixing physical quantities that sound similar in everyday language or choosing a unit that belongs to a different dimension.

  • Forgetting that height is relative to a reference level.
  • Using spring displacement outside the elastic range.
  • Using mass units as force units.

Assumptions and limitations

This page is intended for educational and planning calculations, not professional engineering certification.

This calculator uses idealized physics formulas and the input values you provide. Real systems may require additional effects such as friction, drag, rotation, deformation, losses or measurement uncertainty.

  • Gravity is constant.
  • Spring mode assumes Hooke's-law behavior.
  • Mass and spring constant must be greater than zero.
  • The calculator does not model variable gravity, non-linear springs, damping or energy loss.
  • Potential energy reference choices can change sign.

Frequently asked questions

How is gravitational potential energy calculated?

Potential Energy Calculator uses PE = m x g x h; spring PE = 1/2 x k x x^2. The result is calculated from the values and units entered in the form.

How is spring potential energy calculated?

Potential Energy Calculator uses PE = m x g x h; spring PE = 1/2 x k x x^2. The result is calculated from the values and units entered in the form.

Why does height affect potential energy?

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring. Gravity is constant.

Can potential energy be negative?

Potential Energy Calculator allows signed results only where the physics quantity can carry direction or reference-sign meaning. Divisors such as time, mass and gravity are validated before calculation.

What value of gravity is used?

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring. Gravity is constant.

What is spring constant?

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring. Gravity is constant.

Why is spring displacement squared?

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring. Gravity is constant.

How do I calculate height from potential energy?

Potential Energy Calculator uses PE = m x g x h; spring PE = 1/2 x k x x^2. The result is calculated from the values and units entered in the form.

How is potential energy different from kinetic energy?

Use this calculator when energy is stored by height in a gravity field or by a compressed or stretched linear spring. Gravity is constant.

When should I use Energy Calculator instead?

Potential Energy Calculator is formula-based. Use the related calculator when the question changes physical quantity, and use Conversion tools only when the value is already known.

References

  • NIST Special Publication 811, Guide for the Use of the International System of Units. Relevance: SI unit symbols and derived-unit naming. Last verified: July 21, 2026. Source.
  • BIPM, The International System of Units SI Brochure. Relevance: SI base and derived units used in mechanics. Last verified: July 21, 2026. Source.
  • OpenStax University Physics Volume 1. Relevance: introductory mechanics formulas for motion, force, work, energy and momentum. Last verified: July 21, 2026. Source.

Physics Phase 1 references verified for SI units and mechanics formulas on July 21, 2026.

Educational disclaimer

This calculator provides mathematical results from the values, conventions and methods you enter. Verify important academic, engineering or professional work independently.