Home / Blog / Math & Scientific

Math & Scientific

Calculate Spring Force with Hooke’s Law and Correct Units

Use F = −kx for a linear spring, convert extension to metres, estimate stiffness from measurements, and separate restoring force from stored energy.

Calculate Spring Force with Hooke’s Law and Correct Units

Define the displacement and restoring force

For an ideal linear spring, the restoring force along its axis is F_s = −kx. The positive constant k is stiffness, usually measured in N/m, and x is displacement from the spring's reference position. The minus sign says the restoring force opposes that displacement. If you need only the force magnitude, use k|x|. Decide which direction is positive and where x = 0 before substituting numbers. A spring's total length and its extension are different measurements, even when both are recorded in centimetres or millimetres.

Calculate force from stiffness and extension

Consider a spring with stiffness 300 N/m whose extension is 0.04 m. Its restoring-force magnitude is 300 × 0.04 = 12 N. If the extension is positive, its signed restoring force is −12 N. A slowly applied external force holding it at rest has the opposite direction in this simple balanced setup. The linked Physics Calculator evaluates numerical expressions, so 300*0.04 checks the magnitude and -300*0.04 checks the signed value. It does not infer a spring model from a description or supply a stiffness value for an unknown spring.

Convert the measured change in length

If the unloaded reference length is 200 mm and the current length is 240 mm, the extension is 40 mm, which is 0.040 m. Using the full 240 mm as x would calculate deformation from the wrong reference. Using 40 directly with stiffness in N/m would introduce a factor of 1000. Alternatively, the same stiffness can be written 0.300 N/mm, giving 0.300 × 40 = 12 N. Keep a matched pair of force and length units rather than mixing a converted stiffness with an unconverted displacement.

Estimate stiffness from a static load

Under an ideal vertical static-load model, a hanging mass's weight is balanced by spring force. For an added mass of 0.50 kg and an additional extension of 0.020 m, using g = 9.81 m/s² gives added force 4.905 N and stiffness 4.905/0.020 = 245.25 N/m. This incremental calculation assumes the spring remains linear over that change. Measure after oscillations settle, and distinguish an added load from an existing hanger or preload. The local expression form can check 0.5*9.81/0.02 after you establish those assumptions.

Use more than one point when a preload may exist

Suppose measured applied force is 3 N at extension 0.010 m and 9 N at 0.040 m. The slope is (9 − 3)/(0.040 − 0.010) = 200 N/m. The fitted line through those points is F = 1 + 200x, so simply dividing either force by its extension would give different apparent stiffness values. The 1 N intercept may reflect a preload or a measurement offset that needs interpretation. Two points define a line, but additional measurements are needed to see whether the real force–extension relationship remains linear across the intended interval.

Do not confuse force with elastic potential energy

For the 300 N/m spring extended 0.04 m from its zero-force reference, ideal elastic potential energy is ½kx² = 0.24 J. The final force magnitude is 12 N, but multiplying that final force by 0.04 m gives 0.48 J, twice the correct stored energy. During a slow extension from zero, the ideal force rises linearly from zero to 12 N, so its average is 6 N. This explains the one-half factor. For a preloaded system, use the appropriate energy difference rather than assuming the starting force is zero.

Check whether the linear model applies

Real springs can show friction, hysteresis, nonlinear stiffness, coil contact or permanent deformation. A linear formula describes an assumed operating range; it does not certify that a particular spring can safely carry a load. The local Physics Calculator is an arithmetic expression evaluator without spring dimensions, material data or a force–extension fitting routine. Use it to verify the displayed products and quotients after selecting consistent units. Retain the reference length, load definition, measured interval and sign convention with the result, especially when comparing measurements from different setups.

Use the Physics Calculator

Open Physics Calculator

Source and scope

OpenStax College Physics: Hooke’s law and elastic energy