How to Calculate a Correlation and Say What It Actually Means
Pearson's r is one division away once your pairs are lined up — and one careless sentence away from claiming causation you haven't shown. Here's how to run the calculator, check its arithmetic, and report the number honestly.

Pearson's r measures straight-line association between two variables, scaled to sit between −1 and +1. The calculator takes X values in one field and Y values in the other — same count, paired in order, so the first X goes with the first Y — and on Calculate r it returns three things: r itself, r², and the least-squares best-fit line. Underneath, r is the sum of the (x − x̄)(y − ȳ) cross-products divided by the square root of the product of the two squared-deviation sums. The worked defaults, X = (1, 2, 3, 4, 5) against Y = (2, 3, 5, 4, 6), give cross-products summing to 9 and both squared-deviation sums equal to 10, so r = 9 ÷ √(10 × 10) = 0.9 exactly, r² = 0.81, and the fitted line is y = 1.3 + 0.9x. This guide runs that example, shows you how to read each output, and covers the three traps — outliers, curves and the causation leap — that make a correct number tell a wrong story.
Correlation runs on pairs, so line your data up first
Forget the formula for a minute. The thing that breaks most correlation attempts isn't arithmetic, it's layout. Pearson's r doesn't look at two lists independently; it looks at pairs. The first X value belongs with the first Y value because they were measured on the same person, day, product or trial. Shuffle one list and you haven't tidied the data — you've destroyed it, and the r you get describes pairs that never existed.
So before you open the calculator, get your data into two columns with a shared row meaning. Row 3 of X and row 3 of Y should be two measurements of the same case. Then count. Both lists need the same number of entries, because every X needs its Y partner. The calculator enforces this: paste mismatched lists and it refuses, showing you the counts so you can find the stray value or the missing one. That's not pedantry. A silent mismatch would pair your last X with nothing and quietly shift every pair after the gap.
Two more layout checks. Each list needs some spread. If every X value is identical — a constant list — there's no variation to co-vary with anything, and the formula divides by the product of the two spreads, which is zero. The calculator refuses that case outright rather than printing a fake zero. And scan for the one wild point. A single outlier, far from the rest, can haul r up or down on its own. You don't have to delete it, but you do have to know it's there before you quote the result.
Calculate r in seven steps
With the pairs lined up, the run itself takes under a minute. The time goes on the checks at either end.
- Arrange your data as pairs, so each X value sits in the same row as the Y value measured on the same case.
- Paste the first list into the X values field, separated by commas, spaces or new lines.
- Paste the second list into the Y values (same count, paired in order) field, keeping the pairing order exactly as arranged.
- Check that the two counts match, and scan both lists for a constant run or one value sitting far away from the rest.
- Click Calculate r and read the three outputs: r, r² and the best-fit line.
- Sanity-check r against your pairs: the sign should match the direction the pairs drift, and a value near ±1 should look near-linear when you eyeball them.
- Report r with its context — what the variables are, how many pairs, and what else could explain the pattern — never as a bare number.
Step six catches real errors. If your pairs clearly climb together but r comes back negative, you've pasted a list in reverse or paired the columns wrong. If r comes back at exactly 1 or −1 on measured real-world data, be suspicious rather than pleased: real measurements almost never sit perfectly on a line, and an exact value usually means one variable was computed from the other.
Worked example: the defaults give r = 0.9 exactly
The calculator opens with X = (1, 2, 3, 4, 5) and Y = (2, 3, 5, 4, 6). Leave them in place and click Calculate r. Before you read the outputs, here's the hand version, because this example is tidy enough to check completely. The mean of X is 3 and the mean of Y is 4. Now take each pair's deviations from those means and multiply them together: (−2 × −2) is 4, (−1 × −1) is 1, (0 × 1) is 0, (1 × 0) is 0, and (2 × 2) is 4. The cross-products sum to 9. The squared deviations for X are 4, 1, 0, 1, 4, summing to 10 — and Y's squared deviations are also 4, 1, 1, 0, 4, summing to 10. So r = 9 ÷ √(10 × 10) = 9 ÷ 10 = 0.9, exactly.

The other two outputs follow from r and the pairs. r² is 0.9 squared, which is 0.81. The best-fit line comes out as y = 1.3 + 0.9x: a slope of 0.9 and an intercept of 1.3. Test it against the pairs. At x = 1 the line predicts 1.3 + 0.9, which is 2.2, close to the actual 2. At x = 5 it predicts 1.3 + 4.5, which is 5.8, close to the actual 6. The line isn't threading every point — with r at 0.9 rather than 1, it shouldn't — but it's landing near them all, which is what a strong fit looks like.
Reading the three outputs without overclaiming
Start with r itself. The sign gives direction: positive means Y tends to rise as X rises, negative means Y tends to fall. The size gives tightness around a straight line. Around 0.9, like the worked example, is a strong linear association. Around 0.5 is moderate — a real drift, with plenty of scatter. Near 0 means no linear association, and that wording matters, as the next section shows. Because r is scaled by both variables' spreads, it's unit-free: hours against marks and centimetres against kilograms land on the same −1 to +1 scale, so you can compare strengths across completely different measurements.
r² is the one people quote at parties, so get its sentence right. An r² of 0.81 means 81% of the variance in Y is linearly accounted for by X. Read that slowly. "Accounted for" is bookkeeping language about spread, not a claim about cause. It does not mean X produces 81% of Y, and it doesn't mean the other 19% is noise or error — it's just variation the straight line through X doesn't capture.
The best-fit line is the practical output. Its slope, 0.9 in the example, says how much Y changes on average for a one-unit step in X, in Y's own units. Its intercept, 1.3, is where the line crosses x = 0 — worth reporting, but don't lean on it if 0 sits far outside the range you actually measured. A line fitted on x values from 20 to 80 says nothing trustworthy about x = 0, however clean the r behind it.
The three traps: outliers, curves and the causation leap
Trap one is the outlier. r is built from products of deviations, so a point that's far out in both variables contributes a huge cross-product and can manufacture a strong correlation from a cloud that otherwise shows nothing — or wreck a genuine one. If one pair sits apart from the rest, run the calculator with and without it and report both numbers. Hiding the difference is how a fragile r becomes a false claim.
Trap two is the curve. Pearson's r measures straight-line association only. A perfect parabola — Y rises with X, peaks, then falls symmetrically — can return an r of almost exactly 0 while being completely predictable. So a near-zero r never licenses the sentence "there's no relationship". It licenses "there's no linear relationship", full stop. If your pairs bend when you eyeball them, r is the wrong summary; a rank correlation or fitting the curve itself is the right move.
Trap three is the big one. Correlation is not causation, and a handsome r can't tell you which story produced it. X might drive Y. Y might drive X. A third variable might drive both — ice cream sales and drowning deaths correlate because summer drives each of them. Or the pattern might be chance in a small sample. What separates those stories is design: controls, timing, randomisation. None of that lives in the calculator. So write the sentence the number earned — "these two move together, r = 0.9, across 40 pairs" — and let the investigation into why start there, not end there.
The Verystep Pearson Correlation Coefficient Calculator takes your X values in one field and your Y values (same count, paired in order) in the other. Click Calculate r and it returns r, r² and the best-fit line through your pairs, all in your browser with nothing uploaded.
Last verified November 19, 2026 — X values and Y values (same count, paired in order) fields and the Calculate r button checked against the live Verystep Pearson Correlation Coefficient Calculator, and the worked example recomputed offline: cross-products sum to 9, both squared-deviation sums are 10, so r = 9 ÷ √(10 × 10) = 0.9 exactly, r² = 0.81, and the best-fit line is y = 1.3 + 0.9x with slope 0.9 and intercept 1.3.
Frequently asked questions
What does an r of 0.9 mean in plain words?
A strong positive linear association: as X rises, Y tends to rise, and the pairs sit close to an upward straight line. Its square, r² = 0.81, means 81% of the variance in Y is linearly accounted for by X. It doesn't mean X causes Y, and it doesn't mean the relationship is '90% strong' in any everyday sense — the scale runs from −1 to +1 and measures closeness to a line.
My r came back near zero. Does that prove there's no relationship?
No. It proves there's no linear relationship, which is a narrower claim. A strong curved pattern, such as a symmetric parabola, can score r ≈ 0 while being perfectly predictable. Eyeball your pairs: if they bend, Pearson's r is the wrong summary and a rank correlation or a curve fit will describe the data better.
Why did the calculator refuse my data?
Two refusals are built in. If the X and Y lists have different counts, it stops and shows you the counts, because correlation needs complete pairs. And if either list is constant — every value the same — r is undefined, since the formula divides by that list's spread, which is zero. Something that never varies can't co-vary, so the tool names the problem instead of printing a fake number.
Can one bad data point really change r much?
Yes. r is built from products of deviations, so a point far from the pack in both variables contributes an outsized cross-product. One wild pair can create an apparent correlation or destroy a real one. If you spot an outlier, run the calculation with and without it and report both values, so your reader can see how much of the result rests on that single pair.
Does a strong correlation prove that X causes Y?
No. A strong r is consistent with several stories: X driving Y, Y driving X, a third variable driving both, or coincidence in a small sample. Correlation alone can't distinguish them. Causal claims come from study design — controls, timing, randomisation — not from the size of r. Treat a strong r as a reason to investigate, never as the conclusion.
More guides

The PPWR Empty Space Ratio: Why the 50% Cap Hits Your Shipping Box First
Ask a room of online sellers what the PPWR will change first and most will say labels. The duty with a number in it is quieter: from 2030 at the earliest, no more than half the volume of your shipping box may be empty — and the filler you stuff into it counts as empty.

Counting a Return Window: The EU 14-Day Cooling-Off Period Starts the Day After Delivery
A shop page says “14 days to return”. Fourteen days from when — the order, the dispatch, the delivery? And counted how — in calendar days or working days? EU law answers both questions, and the answers are not the ones most countdown banners use.

How to Check Gift Return Eligibility Without a Receipt
Black Friday is over, the gifts are changing hands, and some of them are the wrong size, the wrong color or the second one you own. There is no receipt — there never is with a gift — so the question is not “can I get my money back?” but “which route does this store actually offer someone in my position, and how long do I have?”