Ask any algebra student to name a line equation. Nine times out of ten, they will say y = mx + b. There is a good reason this formula is so popular. It is simple to remember. It also gives two key facts immediately: how steep the line is, and where it crosses the y-axis.

In algebra, this equation is called slope-intercept form. In this guide, we explore what y = mx + b means. We examine its key properties. We learn how to draw graphs quickly. Finally, we work through four complete examples.

What is slope-intercept form

Slope-intercept form writes a line equation so that y sits alone on the left. It is written as:

y = mx + b

Each letter in the equation has a clear meaning:

  • y is the vertical output coordinate for any point on the line.
  • x is the horizontal input coordinate for that same point.
  • m is the slope of the line, which measures its steepness and direction.
  • b is the y-intercept, where the line crosses the vertical axis at (0, b).

The letter b gives your starting dot on the vertical axis. The letter m tells you how far to step up and right. This lets you sketch a line in seconds. To test your numbers, try our slope-intercept form calculator.

y = mx + bSlope (m = rise/run)y-intercept at (0, b)

Key properties of slope-intercept form

The equation y = mx + b has several helpful geometry properties:

1. Direct picture of steepness and direction

The sign and size of m show what the graph looks like:

  • If m > 0, the line climbs from left to right.
  • If m < 0, the line drops from left to right.
  • If m = 0, the line is flat and simplifies to y = b.
  • A bigger m value means a steeper slope.

2. Parallel lines share the same slope

Lines that never cross must share the same direction. In algebra, two lines are parallel if they have the exact same slope (m₁ = m₂) with different y-intercepts. For example, y = 3x + 2 and y = 3x − 7 run side by side forever.

3. Perpendicular lines have negative reciprocal slopes

When two lines cross at an exact 90-degree angle, their slopes multiply to −1:

m₁ · m₂ = −1 or m₂ = −(1 / m₁)

If your first line has a slope of 2, the perpendicular line has a slope of −1/2.

4. Reading the vertical intercept directly

Set x = 0 to get y = m(0) + b = b. The point (0, b) is always the y-intercept. To find where the line crosses the x-axis, set y = 0 and solve for x: x = −b/m. You can also use our axes intercepts calculator to find both crossings.

xy1. Plot (0, b)2. Rise & runrun forwardrise up

Real world applications of y = mx + b

Many everyday situations start with a fixed base number and grow at a steady rate:

1. Taxi and rideshare fares

A taxi service might charge 4 dollars to pick you up. Then it charges 2 dollars for every mile driven. The total fare y for x miles is:

y = 2x + 4

The slope m = 2 is the cost per mile. The y-intercept b = 4 is the starting charge before you move.

2. Cell phone data plans

Suppose a mobile phone plan costs 35 dollars each month. Extra data costs 5 dollars per gigabyte. The monthly bill y for x extra gigabytes is:

y = 5x + 35

The slope m = 5 is the rate per gigabyte. The intercept b = 35 is the baseline cost. If you use 4 extra gigabytes, your bill is 5(4) + 35 = 55 dollars.

3. Temperature conversion

Converting Celsius (C) to Fahrenheit (F) uses slope-intercept form:

F = (9 / 5)C + 32

Here the slope is 9/5 = 1.8. Each 1-degree rise in Celsius raises Fahrenheit by 1.8 degrees. The y-intercept is 32, where water freezes.

How to graph a line using slope and intercept

Graphing an equation in y = mx + b form takes three quick steps:

  1. Plot the y-intercept: Look at the number b. Put a dot on the vertical y-axis at (0, b).
  2. Count the slope steps: Write m as a fraction. If m is 3, think of it as 3/1. From your first dot, count 1 unit right and 3 units up. Mark your second dot.
  3. Draw the line: Connect the dots with a ruler. Add arrows on both ends.

What happens when a line has a fraction slope

Many algebra problems have fractions for slope, such as y = (2/3)x + 1 or y = −(4/5)x − 2. Fractions are actually very easy to graph.

The top number of the fraction is your rise. It tells you how many units to move up or down.

The bottom number is your run. It tells you how many units to move right.

For example, in y = (2/3)x + 1, start at (0, 1). Count up 2 units. Then count right 3 units. Mark your second dot at (3, 3). If the slope is negative, like −4/5, count down 4 units and right 5 units. A fraction slope gives you a step-by-step path across your grid.

Four worked examples

Here are four diverse examples that show how to apply slope-intercept form in different situations.

Example 1: Finding the equation from a point and slope

Write the equation of a line with slope m = 3 that passes through the point (2, 11).

  1. Start with the formula: y = mx + b.
  2. Substitute the known slope: y = 3x + b.
  3. Substitute the coordinates x = 2 and y = 11 into the equation:
    11 = 3(2) + b
  4. Solve for b:
    11 = 6 + b → b = 11 − 6 = 5
  5. Write the final equation:
    y = 3x + 5

Example 2: Graphing an equation with a negative slope

Graph the line given by the equation y = −2x + 7.

  1. Identify m and b: m = −2 = −2/1 and b = 7.
  2. Plot the vertical intercept at (0, 7).
  3. Use the slope to locate a second point: from (0, 7), move 1 unit to the right and 2 units down. You will land at (1, 5).
  4. Repeat the move: from (1, 5), move 1 unit right and 2 units down to reach (2, 3).
  5. Connect these dots with a clean straight line.

Example 3: Converting from standard form

Convert the equation 3x + 2y = 12 into slope-intercept form and find its slope and intercept.

  1. Subtract 3x from both sides to isolate the y term:
    2y = −3x + 12
  2. Divide every term on both sides by 2:
    y = −(3 / 2)x + 6
  3. Read your parameters: − Slope m = −3/2 (falls 3 units for every 2 units moved right) − y-intercept b = 6 (crosses the vertical axis at (0, 6))

If you ever need to turn an equation back into standard integer form Ax + By = C, you can also verify your steps with our standard form calculator.

Example 4: A horizontal line

Write the equation of a line that passes through (4, −3) and has a slope of m = 0.

  1. Plug m = 0 into slope-intercept form:
    y = 0(x) + b → y = b
  2. The line passes through (4, −3), so y always equals −3.
  3. The final equation is simply:
    y = −3
    Every flat horizontal line has the form y = c, where c is a constant.

Comparing common linear equation forms

Different equation formats serve different goals:

Equation FormFormulaBest Used When
Slope-Intercept Formy = mx + bYou want to graph quickly or see the y-intercept
Point-Slope Formy − y₁ = m(x − x₁)You know the slope and any single point (x₁, y₁)
Standard FormAx + By = CYou want clean whole numbers without fractions
Two-Intercept Form(x / a) + (y / b) = 1You know the two axis crossing points (a, 0) and (0, b)

Common mistakes when using slope-intercept form

Watch out for these frequent mistakes when working with y = mx + b:

  1. Forgetting to get y alone first: In 2y = 6x + 8, the slope is not 6. Divide by 2 first to get y = 3x + 4. The true slope is 3.
  2. Mixing up m and b: The slope m always multiplies x. The y-intercept b is the standalone number. In y = 8 − 4x, the slope is −4 and the y-intercept is 8.
  3. Trying to write vertical lines in y = mx + b: A vertical line has an undefined slope. It never crosses the y-axis. Write a vertical line as x = k.
  4. Sign errors when b is negative: In y = 5x − 9, b equals −9, not +9. The line crosses below zero at (0, −9).

Slope-intercept form FAQs

Can the y-intercept b be equal to zero?

Yes. When b = 0, the equation is y = mx. This line passes straight through the origin (0, 0).

Why can vertical lines not be written in slope-intercept form?

A vertical line has no horizontal run. Dividing by zero gives an undefined slope. There is no real number for m, so y = mx + b cannot represent it.

What is the slope of the line y = x?

In the equation y = x, the number in front of x is 1. The constant b is 0. So m = 1 and b = 0. The line forms a 45-degree angle through the origin.

How do I check if my graph of y = mx + b is correct?

Pick any x-number, plug it in, and calculate y. If that coordinate pair sits right on your plotted line, your graph is correct. You can also confirm coordinates with our slope calculator or explore how to write lines from one point using our point-slope form guide.

Is slope-intercept form the same as standard form?

No. Standard form places x and y together: Ax + By = C. Slope-intercept form keeps y alone: y = mx + b. Both describe the exact same straight line. Standard form is often preferred when solving systems of equations.