Connect via MCP →

Enter Calculation

Formula

Advertisement

Results

Spring Force F
-30
force units
Magnitude 30
Equation F = -k x (Hooke's Law)

What is Hooke's Law?

Hooke's Law describes the behaviour of an ideal elastic spring: the restoring force is directly proportional to how far the spring is stretched or compressed from its natural length. Written as \(F = -kx\), F is the spring (restoring) force, k is the spring constant (stiffness), and x is the displacement from equilibrium. The negative sign means the force always points back toward the rest position. This is a universal physics relation valid everywhere within a spring's elastic (linear) regime.

Spring stretched and compressed showing restoring force opposite to displacement
Hooke's Law: the spring's restoring force always opposes the displacement x.

How to use this calculator

Pick what you want to solve for: spring force, spring constant, displacement, or the acceleration of an attached mass. Then enter the known quantities and choose their units — every value is converted to SI (newtons, newtons per meter, meters, kilograms) before the calculation and the answer is converted back to your selected display unit. Use the significant-figures dropdown to round the displayed result, or leave it on "auto" for natural precision.

The formula explained

The core relation is \(F = -kx\). Rearranging: the spring constant is $$k = \frac{\left|F\right|}{\left|x\right|}$$ and the displacement is $$x = \frac{\left|F\right|}{\left|k\right|}$$ For a mass m attached to the spring, Newton's second law gives the instantaneous acceleration $$a = \frac{F}{m} = \frac{-kx}{m}$$ Magnitudes are used when solving for k or x; the displayed force keeps its sign to stay faithful to \(F = -kx\).

Advertisement
Linear graph of spring force versus displacement passing through origin with slope k
Force is proportional to displacement; the slope of the line is the spring constant k.

Worked example

A spring has stiffness k = 200 N/m and is stretched x = 0.15 m. The spring force is $$F = -(200 \times 0.15) = -30\ \text{N}$$ a magnitude of 30 N directed back toward equilibrium. If a 2 kg mass were attached and held at that displacement, its instantaneous acceleration would be $$a = \frac{-30}{2} = -15\ \text{m/s}^2$$

FAQ

Why is there a negative sign? It indicates the restoring force opposes the displacement — stretch the spring and it pulls back, compress it and it pushes out.

When does Hooke's Law fail? Beyond the elastic limit the spring deforms permanently and force is no longer linear in displacement, so the formula no longer applies.

Can I enter negative displacement? Yes. A negative x represents compression instead of extension; the sign propagates through the linear relation.

Last updated: