# How to find the slope of a line

Canonical: https://duckyhelper.com/learn/algebra-1/slope/
Updated: 2026-10-01

Slope tells you how steep a line is and which way it goes. It is the change in y divided by the change in x between any two points on the line, often called rise over run. A positive slope rises from left to right, a negative slope falls, a horizontal line has slope 0, and a vertical line has an undefined slope. Parallel lines share a slope.

## The key idea

Pick any two points on a line, \((x_1, y_1)\) and \((x_2, y_2)\). The slope \(m\) is how far you go up or down (the rise) for each step you go across (the run):

$$
m = \frac{\text{rise}}{\text{run}} = \frac{y_2 - y_1}{x_2 - x_1}
$$

A slope of 3 means: move 1 to the right, go up 3. A slope of \(-\frac{1}{2}\) means: move 2 to the right, go down 1. In a word problem, slope is a rate, like dollars per hour or centimeters per day.

**The four kinds of slope**

| Line | Slope | Example |
| --- | --- | --- |
| Rises left to right | positive | \(y = 2x + 1\) has slope 2 |
| Falls left to right | negative | \(y = -3x + 4\) has slope \(-3\) |
| Horizontal | 0 (no rise at all) | \(y = 5\) |
| Vertical | undefined (the run is 0, and you cannot divide by 0) | \(x = -2\) |

**Parallel** lines have the same slope. **Perpendicular** lines have slopes that are negative reciprocals, so they multiply to \(-1\): a line with slope \(\frac{2}{3}\) is perpendicular to one with slope \(-\frac{3}{2}\).

## Worked examples

**Example 1: slope from two points**

Problem: Find the slope of the line through \((2, -1)\) and \((6, 7)\).

1. Call \((2, -1)\) the first point and \((6, 7)\) the second. Put the y values on top and the x values on the bottom, in the same order.

   $$
   m = \frac{7 - (-1)}{6 - 2}
   $$
2. Subtracting a negative is adding.

   $$
   m = \frac{8}{4} = 2
   $$
3. Sense check: the second point is to the right and higher, so the slope should be positive. It is.

Answer: \(m = 2\)

**Example 2: a negative fraction slope**

Problem: Find the slope of the line through \((-3, 4)\) and \((5, -2)\).

1. Same order on top and bottom.

   $$
   m = \frac{-2 - 4}{5 - (-3)}
   $$
2. Simplify the top and the bottom, then reduce the fraction.

   $$
   m = \frac{-6}{8} = -\frac{3}{4}
   $$
3. Sense check: the line goes down 3 for every 4 to the right.

Answer: \(m = -\frac{3}{4}\)

**Example 3: slope from an equation, then a perpendicular slope**

Problem: Find the slope of \(4x - 6y = 12\), and the slope of any line perpendicular to it.

1. Solve for y. First subtract \(4x\) from both sides.

   $$
   -6y = -4x + 12
   $$
2. Divide every term by \(-6\). The number in front of x is the slope.

   $$
   y = \frac{2}{3}x - 2
   $$
3. A perpendicular slope is the negative reciprocal: flip \(\frac{2}{3}\) and change its sign. Check that the two slopes multiply to \(-1\).

   $$
   \frac{2}{3} \cdot \left(-\frac{3}{2}\right) = -1
   $$

Answer: The slope is \(\frac{2}{3}\). A perpendicular line has slope \(-\frac{3}{2}\).

**Example 4 (test-hard): a missing coordinate**

Problem: The line through \((k, 9)\) and \((2, -3)\) has slope 3. What is \(k\)?

1. Write the slope formula with the unknown and set it equal to 3.

   $$
   \frac{-3 - 9}{2 - k} = 3
   $$
2. Multiply both sides by \(2 - k\).

   $$
   -12 = 3(2 - k)
   $$
3. Distribute.

   $$
   -12 = 6 - 3k
   $$
4. Add \(3k\) and add 12 to both sides.

   $$
   3k = 18
   $$
5. Divide by 3, then check: \(\frac{-3 - 9}{2 - 6} = \frac{-12}{-4} = 3\).

   $$
   k = 6
   $$

Answer: \(k = 6\)

## Common mistakes

- **Mixing the order.** \(\frac{y_2 - y_1}{x_1 - x_2}\) gives the right size with the wrong sign. Fix: whichever point you start with on top, start with it on the bottom too.
- **Putting x on top.** Run over rise gives the reciprocal, like \(\frac{1}{2}\) instead of 2. Fix: y goes up and down, and "up" is on top.
- **Dropping the sign when subtracting a negative.** \(7 - (-1)\) is 8, not 6.
- **Mixing up zero and undefined.** A flat line like \(y = 5\) has slope 0. A straight-up line like \(x = -2\) has no slope at all (undefined).
- **Reading the slope from the wrong form.** In \(4x - 6y = 12\), the slope is not 4. Fix: solve for y first, or use the shortcut below.

## Quick methods

> **Tip: Standard form shortcut**
>
> For a line written as \(Ax + By = C\), the slope is \(-\frac{A}{B}\). For \(4x - 6y = 12\) that is \(-\frac{4}{-6} = \frac{2}{3}\), the same answer as Example 3. It comes straight from solving for y, so it always works.

> **Note: From a graph, count boxes**
>
> Find two points where the line crosses grid corners exactly. Count how many boxes up or down (rise) and how many to the right (run) from the left point to the right point. Down counts as negative.

## Practice

**5 practice questions**

1. What is the slope of the line through \((1, 5)\) and \((4, -1)\)?
   A. \(-2\)
   B. \(-\frac{1}{2}\)
   C. \(2\)
   D. \(\frac{4}{3}\)

   Answer: \(-2\). \(\frac{-1 - 5}{4 - 1} = \frac{-6}{3} = -2\). The choice \(-\frac{1}{2}\) is run over rise, and 2 loses the sign (the line falls, so the slope must be negative).

2. Which line has an undefined slope?
   A. \(y = 5\)
   B. \(x = -2\)
   C. \(y = x\)
   D. \(y = -2x\)

   Answer: \(x = -2\). \(x = -2\) is a vertical line. Any two points on it have the same x, so the run is 0 and the slope would mean dividing by 0. \(y = 5\) is horizontal, with slope 0.

3. What is the slope of \(3x + 5y = 10\)?
   A. \(3\)
   B. \(-\frac{3}{5}\)
   C. \(\frac{3}{5}\)
   D. \(2\)

   Answer: \(-\frac{3}{5}\). Solve for y: \(5y = -3x + 10\), so \(y = -\frac{3}{5}x + 2\). The slope is \(-\frac{3}{5}\). The 2 is the y-intercept, and 3 is just the x coefficient before solving for y.

4. What is the slope of a line perpendicular to \(y = -4x + 1\)?
   A. \(4\)
   B. \(-4\)
   C. \(\frac{1}{4}\)
   D. \(-\frac{1}{4}\)

   Answer: \(\frac{1}{4}\). Flip \(-4\) to get \(-\frac{1}{4}\), then change the sign: \(\frac{1}{4}\). Check: \(-4 \cdot \frac{1}{4} = -1\). The choice \(-4\) is the parallel slope.

5. A plant was 4 cm tall on day 2 and 13 cm tall on day 8. If it grew at a steady rate, what is the slope of its height graph, and what does it mean?
   A. 1.5: the plant grows 1.5 cm per day
   B. 1.5: the plant was 1.5 cm tall on day 0
   C. 0.67: the plant grows 0.67 cm per day
   D. 9: the plant grows 9 cm per day

   Answer: 1.5: the plant grows 1.5 cm per day. Slope is change in height over change in days: \(\frac{13 - 4}{8 - 2} = \frac{9}{6} = 1.5\) cm per day. A slope is always a rate, never a starting value. 0.67 is days over centimeters (upside down), and 9 forgets to divide by the 6 days.

## Frequently asked questions

### What is the slope formula?

For two points \((x_1, y_1)\) and \((x_2, y_2)\), the slope is \(m = \frac{y_2 - y_1}{x_2 - x_1}\). It is the change in y divided by the change in x. It works for any two points on a straight line and always gives the same answer.

### What is the difference between zero slope and undefined slope?

Zero slope means the line is flat (horizontal), like \(y = 5\): there is no rise. Undefined slope means the line is straight up and down (vertical), like \(x = -2\): there is no run, and you cannot divide by zero.

### Does it matter which point I call the first point?

No. You get the same slope either way, as long as you use the same order on the top and the bottom. Swapping both just multiplies the top and the bottom by \(-1\), which cancels.

### How do I find the slope of a parallel or perpendicular line?

A parallel line has exactly the same slope. A perpendicular line has the negative reciprocal: flip the fraction and change the sign. So for slope \(\frac{2}{3}\), the perpendicular slope is \(-\frac{3}{2}\). A slope of 0 is perpendicular to an undefined slope.

## Related

- [Slope-intercept form and how to write the equation of a line](https://duckyhelper.com/learn/algebra-1/slope-intercept-form/)
- [How to solve systems of equations](https://duckyhelper.com/learn/algebra-1/systems-of-equations/)
- [Linear functions and slope on the SAT](https://duckyhelper.com/learn/sat-math/linear-functions/)
- [Algebra 1 study guides](https://duckyhelper.com/learn/algebra-1/)

## Try asking Ducky

- "I got 2 but the answer is -2. Did I subtract in the wrong order?"
- "How do I find the slope from this graph on my screen?"
- "What does the slope mean in this word problem?"

## Get DuckyHelper

Free to start. The web app works in any browser, Chromebooks included; the Mac app can also draw on your real screen. [Try it free in your browser](https://app.duckyhelper.com/?utm_source=duckyhelper.com&utm_medium=learn) or [Get the Mac app](https://duckyhelper.com/download/)
