Linear regression calculator
Slope, intercept and R² — and the residuals, which are the evidence for whether a straight line was the right shape at all and which almost no calculator shows you. Nothing you type here leaves your browser — it is worked out on your own device, so there is nothing to send and nothing to log.
What R² does not mean
R² is the share of the variation in y that the line accounts for. It is not the probability the relationship is real, it is not a measure of whether the slope matters, and a high value does not mean a line was the right shape.
For a single predictor it is exactly the square of Pearson's r, and the page shows that rather than computing it twice — people treat the two as separate facts about their data when one is the other.
The clearest way to see what it misses: three of the four datasets in Anscombe's quartet have R² = 0.67 and a line fitted through them is wrong in three different ways.
The residuals are the interesting part
A regression is a claim that a line explains the data. The residuals — the leftovers, what each point missed by — are the evidence for or against that claim, and they are what almost no calculator shows you.
Scattered randomly about zero: the line was a reasonable shape. Curving: it was not, and a straight line is fitting a bend. Fanning out: the spread grows with x, and the standard error above is understating things.
And the line does not know where your data ended
The equation will happily give you a y for any x you put in, including values far outside anything you measured. It has no way of telling you that it is guessing.
The standard error of the slope is the honest summary of how firmly the data pins it down. With few points or a lot of scatter it is large, and a slope you cannot pin down is a slope you should not extrapolate from.