Interpolation Calculator

Linear interpolation between two known points — plus extrapolation warnings and the inverse solve (find x for a given y).

100% FreeNo sign-upPrivate — runs in your browser

If the known value lies outside the interval between the two points, the result is an extrapolation and is flagged as less reliable.

—

interpolated result

Result
—
Slope of the line
—
Position between the points
—
Interpolation or extrapolation?
—
Line equation
—
Copied to clipboard

How to use this tool

1
Choose what to solve for

y for a given x, or x for a given y (inverse).

2
Enter the two known points

Both points define the straight line used for the estimate.

3
Enter the known value

The x (or y) you want to evaluate.

4
Check interpolation vs extrapolation

Values inside the interval are interpolated; values outside are flagged as extrapolations.

Formula & worked example

Linear interpolation: y = y1 + (x – x1) x (y2 – y1) / (x2 – x1). Inverse: x = x1 + (y – y1) x (x2 – x1) / (y2 – y1). Both assume the relationship is a straight line between the points.

Points (0, 0) and (10, 100), x = 4: y = 0 + 4 x 100/10 = 40. At x = 12 the same line gives 120, but that is an extrapolation beyond the known data and is flagged.

Limitations — read this before you rely on it

Linear interpolation assumes a straight line, which real data rarely follows exactly; the further outside the interval, the less trustworthy the result. It also cannot be used when x1 equals x2 (a vertical line).

Frequently asked questions

Estimating a value between two known points by assuming a straight line joins them.

Estimating outside the range of known data by extending the same line — useful, but riskier than interpolation.

When the underlying relationship really is linear between the points; otherwise it is an approximation.

Yes, with splines or polynomial interpolation, but this calculator uses the standard two-point linear method.

It runs the same line equation backwards: given y, it finds the x on the line with that y-value.