What is the Regression Calculator?
Fit a linear regression line to (x, y) data with this free online regression calculator. Enter paired values and get the slope, intercept, equation y = mx + b, Pearson correlation r, R², optional predictions, and step-by-step least-squares work. Runs entirely in your browser with no signup.
How to use the Regression Calculator
- Enter matching x and y value lists.
- Optionally enter an x value to predict ŷ.
- Click Calculate.
- Review the regression equation, r, and R².
- Copy the equation or the full summary with steps.
Common use cases
- Fitting y = 2x to points (1,2), (2,4), (3,6)
- Finding slope and intercept for lab experiment data
- Predicting ŷ at x = 6 from a fitted line
Frequently asked questions
- What type of regression does this use?
- Ordinary least-squares (OLS) linear regression — the line that minimizes the sum of squared vertical residuals.
- What is R²?
- The coefficient of determination — the fraction of variance in y explained by the linear model. R² = r² for simple linear regression.
- How do I predict a y value?
- Enter an x in the optional Predict field. The calculator returns ŷ = mx + b on the fitted line.
- What are the limits?
- At least 2 (x, y) pairs, up to 10,000. All x values cannot be identical.