The Point-Slope Method
Finding the equation of a line starts with slope-intercept form: y = mx + b. The m is the slope, the rate of change. The b is where the line crosses the y-axis. If you know a point on the line and the slope, you plug into point-slope form, which is y - y1 = m(x - x1), then rearrange it. That's usually the fastest route if you have a point and a slope already calculated. If you only have two points, calculate the slope first using m = (y2 - y1) / (x2 - x1). Order matters here. You subtract the y-coordinates in the same order you subtract the x-coordinates. Flip the order on one side and you get the wrong sign, and the whole equation collapses. Let's say your points are (3, 7) and (8, 19). The slope is (19 - 7) / (8 - 3), which gives you 12 / 5, or 2.4. Once you have the slope, substitute back into point-slope form using either point. I use (3, 7) because the numbers are smaller and less prone to arithmetic errors: y - 7 = 2.4(x - 3). Distribute and solve for y, and you get y = 2.4x - 0.2. Check it by plugging in the other point. 19 should equal 2.4 times 8 minus 0.2. It does.
There's a faster way to find b without distributing. Use the fact that b = y1 - mx1. Take one point and subtract the slope times its x-value. With the same example: b = 7 - (2.4 × 3) = 7 - 7.2 = -0.2. Same result. One fewer step. This shortcut saves time on exams where you're working under pressure and your handwriting deteriorates.
When The Standard Approach Breaks Down
I spent an afternoon last year debugging a data pipeline where we needed to reconstruct a line from sensor readings. Two points looked clean: (0.0003, 4.7) and (0.0006, 4.7007). Both were measured by a low-cost analog-to-digital converter. The slope came out to about 2.333, and the y-intercept was essentially 4.7. Standard calculation. Fine. Except the line needed to pass through an additional constraint point: (0.00045, 4.70035). When I plugged it in, the fit was off by 0.00018. That seemed small until I realized it was 0.5% of the signal range, and our tolerance band was 0.1%. Three points that should have been collinear weren't, because measurement noise had accumulated differently at each sample. The workaround was to stop looking for a line through two points and instead use least squares regression across all available data points. Instead of forcing the equation to hit any two specific readings, I fed all twelve sensor readings into a linear regression and let it find the best-fit line. The resulting slope was 2.331 instead of 2.333, and the intercept shifted to 4.6996. The prediction error dropped below 0.00005 across the board. Two-point interpolation looked elegant on paper. It fell apart in practice when the measurements themselves carried uncertainty.
Get the Full Details

This is the thing most textbooks don't make clear. Finding a line through two points assumes those points are exact. Real data is almost never exact. When precision matters, moving from point-based interpolation to regression-based fitting is usually the right call, and it takes roughly the same amount of time if you have a spreadsheet or a basic calculator with statistical functions.
The Forms You Actually Need
Slope-intercept form: y = mx + b. Best for graphing and quick interpretation. You can read the slope and y-intercept directly. Standard form: Ax + By = C, where A, B, and C are integers and A is non-negative. Useful in engineering contexts where you need to avoid fractions. Convert from slope-intercept by moving the x term to the left, clearing decimals by multiplying through, and making sure the leading coefficient is positive. Point-slope form: y - y1 = m(x - x1). Best for deriving the equation quickly from a known point and slope. This is the workhorse form for actual calculations. Slope-intercept is better for presenting results.
I find most people carry around slope-intercept form because they learned it first and use it exclusively. That works fine until you encounter a vertical line, where the slope is undefined and slope-intercept form literally cannot represent the line. A vertical line through x = 5 is just x = 5. Nothing about y. That's the edge case that catches people on tests and in practice alike.

Pitfalls I See Repeatedly
The most common mistake is treating a single point as sufficient to define a unique line. It isn't. Through any single point, an infinite number of lines pass. You need at least two points, or one point plus a slope, or some other constraint. When I was tutoring calculus students, roughly a third of them would ask how to find the equation of a line given only one point, and I had to explain that the problem is underdetermined before we could continue. Another issue is confusing slope with intercept. The slope is a ratio, dimensionless if the axes share units. The intercept is an absolute position on the y-axis. Mixing them up when writing the final equation gives you something that looks structurally correct but is numerically wrong. Also worth noting: the two-point slope formula fails silently when x2 equals x1. The denominator becomes zero, and depending on your calculator or software, you'll either get an error message or an overflow value that looks almost right. A vertical line has no numerical slope. The equation is simply x equals a constant. There is no workaround within the y = mx + b framework. Accept it and move on.
A Quick Decision Tree
If you have two points, compute the slope and pick either point-slope or the b shortcut. If you have one point and a slope, go straight to point-slope and rearrange. If you have one point and need a perpendicular or parallel line, use the slope relationship first: parallel lines share the same slope, perpendicular lines have slopes that multiply to -1. If your data has measurement error or more than two points, skip direct interpolation and run a regression. It usually converges in seconds on any modern tool and gives you a more reliable answer. The underlying principle is straightforward: a line is defined by its rate of change and one anchored position. Everything else follows from that. The algebra is mechanical. The mistakes come from rushing the arithmetic or applying the wrong method to the wrong situation.