Elastic Potential Energy Calculator

Calculate the elastic potential energy of a spring given its spring constant and length of compression or stretching. Metric and imperial units with output in Joules (J, kJ, MJ), Watt-hours (Wh, kWh), calories (Cal, kCal), and foot-pound-force (ft-lbf). The calculator can also be used to solve for the spring constant or change in length.

N/m
Share calculator:

Embed this tool:
get code     

Created by Portrait of the tool author, Georgi Georgiev Georgi Georgiev
Last updated: Aug 24, 2026


    Quick navigation
  1. Using the elastic potential energy calculator
  2. Elastic potential energy formula
  3. Calculation examples

    Using the elastic potential energy calculator

This elastic potential energy calculator is useful for estimating the energy of a spring under compression or stretch resulting in a change of its length (a.k.a. deformation length). The elastic energy (sometimes called strain energy) is the amount of energy the spring will release once the force stretching it compressing it no longer works.

To calculate the potential energy you need to know the spring constant and the change in length. The calculator can also be used to solve for any of the other values: deformation length and the spring constant. The respective input fields will be hidden or displayed upon selecting what you want to use the calculator for. When solving for length you need to know the spring constant value and the potential energy stored, while when solving for the spring constant you need the change in length and energy.

The output of the tool is in Joules (J, kJ, MJ), Watt-hours (Wh, kWh), calories (Cal, kCal) and foot-pounds (ft-lbf). When the output of the tool is length it is in both metric units and imperial units.

If you are interested in gravitational potential energy, check out our gravitational potential energy calculator.

    Elastic potential energy formula

In physics, the formula for elastic potential energy (PE or sometimes PEe) expressed in terms of the spring's spring constant (k) and its deformation length relative to a chosen reference level (Δx).

elastic potential energy

Δx is negative when the spring is under compression and positive if it is being stretched.

This equation is the core of this online elastic potential energy calculator and it shows the relationship between deformation length and energy depends only on the spring constant. An object has higher potential energy if it is under greater compression or stretch, and vice versa. Since the energy grows with the square of the change in length, any subsequent change of the same length requires more energy to achieve than the previous such change. The formula also shows that an object with a larger spring constant has a higher elastic energy, all else being equal.

Calculate change in length of a spring

Solving for deformation length can easily be done via reordering of the equation:

change in length via potential energy

Find the spring constant

To solve for the spring constant emply the equation:

spring constant via potential energy

in which "PE" is potential energy and l is deformation length.

    Calculation examples

Elastic potential energy is mainly used in structural and machine engineering and in the design of various spring-loaded devices.

Example 1: A spring has a string constant of 500 N/m and is being compressed resulting in its length being shortened by 10 cm. Find the spring's current potential energy? Using the first elastic potential energy formula above and replacing the respective values we get PE = 500 · 102 = 2.50 J.

Example 2: What is the elongation of a string with a string constant of 400 N/m and strain energy measured at 100 J? Since we know both the constant and the energy stored by the string deformation, we can use the second equation to figure out the change in length: Δx = √ (2 · 100 / 400) = √0.5 = 0.7071 m or 70.71 cm.

Example 3: A spring needs to pull with a force of 200 J when stretched. If the constant is 10,000 N/m, how long should the string be stretched in order to reach that level of potential energy? The answer is again in the second elastic potential energy equation from which we get: Δx = √ (2 · 200 / 10000) = √0.04 = 0.20 m or 20 cm.

    Cite this calculator & page

Cite results from this online calculator or information on this page by choosing a citation format:

Georgiev, G.Z. (n.d.). Elastic Potential Energy Calculator. GIGAcalculator.com. Retrieved Aug 26, 2026, from https://www.gigacalculator.com/calculators/elastic-potential-energy-calculator.php