Solve for X Calculator

Stuck on an equation and need to find what X actually equals? You're in the right place. A solve for X calculator takes the equation you're working with and isolates the variable, walking you through the math so the answer makes sense rather than just appearing out of nowhere. Whether you're dealing with a simple one-step problem or something messier with fractions on both sides, the tools and explanations here cover the full range. Plug in your equation, follow the steps, and you'll have the value of X in no time.

Enter Details

Solve ax + b = c

x +
=

Result

Linear equation

Note — This result is an estimate. Talk to a healthcare provider for personalized guidance.

How to Solve for X

Solving for X means rearranging an equation until X is alone on one side and a number is on the other. That's really all it is. The trick is doing the same operation to both sides every time you make a move, so the equation stays balanced.

Think of it like a scale. If you add 5 to the left side, you have to add 5 to the right side too. Subtract, multiply, divide — the rule is the same no matter what operation you use. Break that rule and your answer will be wrong, even if your arithmetic is perfect.

A few things to keep in mind as you work:

  • Simplify each side before you start moving terms around.
  • Combine like terms whenever you can.
  • Undo addition and subtraction first, then multiplication and division (when working backwards from the variable).
  • Check your answer by plugging X back into the original equation.

Find the Value of X in an Equation

Finding the value of X comes down to identifying what's being done to X and then reversing those operations one at a time. If X has been multiplied by 3 and then had 7 added to it, you subtract 7 first, then divide by 3. You're unwinding the equation in reverse order.

For example, take 3x + 7 = 22. Subtract 7 from both sides to get 3x = 15, then divide both sides by 3 to land on x = 5. Clean and straightforward once you see the pattern.

The value you find should always satisfy the original equation. If you substitute x = 5 back into 3x + 7 and don't get 22, something went sideways and it's worth retracing your steps.

Linear Equation Solver

A linear equation is any equation where the variable appears to the first power, meaning no exponents, no x-squared, nothing like that. The graph of a linear equation is always a straight line, which is where the name comes from. These are the most common type of equation you'll run into in algebra, and they follow a very predictable solving process.

The standard form looks like ax + b = c, where a, b, and c are numbers. Your job is to get x by itself. Subtract b from both sides, then divide by a. Done. Of course, real problems often look a bit messier than that tidy formula, which is why it helps to break things into categories.

One-Step Equations

One-step equations need exactly one operation to solve. The variable is already isolated except for one number attached to it by addition, subtraction, multiplication, or division.

  • Addition: x + 9 = 15 → subtract 9 from both sides → x = 6
  • Subtraction: x - 4 = 11 → add 4 to both sides → x = 15
  • Multiplication: 6x = 42 → divide both sides by 6 → x = 7
  • Division: x/3 = 8 → multiply both sides by 3 → x = 24

These are the building blocks. If you're comfortable with one-step equations, everything else in algebra is just a longer version of the same idea.

Multi-Step Equations

Multi-step equations require two or more operations to isolate x. The process is the same as one-step, just repeated. A good habit is to always handle addition and subtraction before multiplication and division when you're working backwards toward x.

Take 2x + 5 = 17. First, subtract 5 from both sides: 2x = 12. Then divide by 2: x = 6. Two steps, one answer.

Sometimes you'll also need to distribute first. With something like 3(x + 4) = 21, distribute the 3 to get 3x + 12 = 21, then subtract 12 to get 3x = 9, then divide by 3 to get x = 3. The more comfortable you get with the order of operations, the faster these move.

Solve for X with Variables on Both Sides

When X shows up on both sides of the equation, the first move is to get all the variable terms on one side and all the constants on the other. You do this by adding or subtracting one of the variable terms from both sides.

Say you have 5x + 3 = 2x + 12. Subtract 2x from both sides: 3x + 3 = 12. Now subtract 3: 3x = 9. Divide by 3: x = 3. The variable is gone from one side, and you're back to a standard multi-step equation.

A common mistake here is forgetting to subtract the entire term, not just the number part. If you see 4x on the right side, you move the whole 4x, not just the 4. Keep that in mind and these problems become much less intimidating.

Also worth knowing: if you end up with something like 0 = 0 after simplifying, the equation has infinitely many solutions. If you get a false statement like 3 = 7, there's no solution at all.

Quadratic Equation Solver

A quadratic equation has x raised to the second power, written as x². The standard form is ax² + bx + c = 0. These equations can have two solutions, one solution, or no real solutions at all, which makes them a step up in complexity from linear equations.

There are a few ways to solve them: factoring, completing the square, and the quadratic formula. Factoring is the fastest when it works. The quadratic formula always works, no matter what the numbers look like. Most people end up relying on the formula for anything that doesn't factor neatly.

Factoring Method

Factoring works by rewriting the quadratic as a product of two binomials, then setting each one equal to zero. It's quick and clean when the numbers cooperate.

For x² + 5x + 6 = 0, you're looking for two numbers that multiply to 6 and add to 5. That's 2 and 3. So you can rewrite it as (x + 2)(x + 3) = 0. Set each factor to zero: x + 2 = 0 gives x = -2, and x + 3 = 0 gives x = -3. Two solutions.

The factoring method falls apart when there are no nice integer pairs that work out. If you spend more than a minute hunting for the right factors and can't find them, it's faster to just use the quadratic formula instead.

Quadratic Formula Method

The quadratic formula is the universal backup plan. It works on every quadratic equation, no guessing required. The formula is:

x = (-b ± √(b² - 4ac)) / 2a

Plug in your values of a, b, and c from the standard form ax² + bx + c = 0, and calculate. The ± symbol means you'll get two answers: one where you add the square root and one where you subtract it.

The expression inside the square root, b² - 4ac, is called the discriminant. If it's positive, you get two real solutions. If it equals zero, you get exactly one. If it's negative, there are no real solutions (only complex ones). Checking the discriminant first can save you some work.

For example, with 2x² + 3x - 2 = 0, a = 2, b = 3, c = -2. The discriminant is 9 + 16 = 25. So x = (-3 ± 5) / 4, giving x = 1/2 or x = -2.

Algebraic Equation Solver

Algebra covers a wide range of equation types, and not all of them fit neatly into the linear or quadratic categories. An algebraic equation solver handles the broader set: equations with absolute values, rational expressions, systems of equations, and more.

The core strategy stays the same regardless of the type. Simplify, isolate, solve, check. What changes is the specific technique you use to simplify. With absolute value equations, for instance, you split into two cases because the expression inside can be positive or negative. With rational equations (fractions with variables in the denominator), you multiply through by the least common denominator to clear the fractions before solving.

Always watch for extraneous solutions when you've done something like square both sides or multiply by a variable expression. Plug your answers back into the original equation to make sure they actually work. It only takes a second and it can save you from turning in a wrong answer with total confidence.

Solve for X with Fractions and Decimals

Fractions and decimals in an equation can look scary, but the fix is usually simple: get rid of them early.

For fractions, find the least common denominator of all the fractions in the equation and multiply every term on both sides by that number. The fractions cancel out and you're left with a cleaner equation to solve. For example, with (x/2) + 3 = 7, multiply everything by 2: x + 6 = 14, so x = 8.

For decimals, multiply every term by a power of 10 that eliminates the decimal points. If your equation has tenths, multiply by 10. Hundredths, multiply by 100. So 0.5x + 1.2 = 3.7 becomes 5x + 12 = 37 after multiplying by 10. Then 5x = 25, and x = 5.

Working with whole numbers is almost always easier, and this approach keeps the math cleaner from start to finish. Just make sure you multiply every single term, not just the ones with fractions or decimals.

Solve for X Formula and Rules

A few core rules govern every solve-for-x problem, no matter the equation type. Knowing them cold makes the whole process faster.

  • Addition Property of Equality: Add the same number to both sides and the equation stays true.
  • Subtraction Property of Equality: Subtract the same number from both sides.
  • Multiplication Property of Equality: Multiply both sides by the same nonzero number.
  • Division Property of Equality: Divide both sides by the same nonzero number.
  • Distributive Property: a(b + c) = ab + ac. Use this to expand expressions before combining like terms.

For linear equations, the formula to keep in mind is ax + b = c → x = (c - b) / a. For quadratics, the quadratic formula x = (-b ± √(b² - 4ac)) / 2a is the go-to when factoring doesn't pan out.

One more rule worth repeating: whatever you do to one side, you do to the other. That's the whole foundation. Everything else is just applying the right operation in the right order.

Step-by-Step Solve for X Examples

Seeing the process in action makes it stick a lot better than reading about it. Here are a few worked examples across different equation types.

Example 1: Simple Linear Equation
Equation: 4x - 8 = 20
Add 8 to both sides: 4x = 28
Divide by 4: x = 7

Example 2: Variables on Both Sides
Equation: 7x - 3 = 4x + 9
Subtract 4x from both sides: 3x - 3 = 9
Add 3: 3x = 12
Divide by 3: x = 4

Example 3: Equation with Fractions
Equation: (x/3) + 2 = 6
Multiply everything by 3: x + 6 = 18
Subtract 6: x = 12

Example 4: Quadratic by Factoring
Equation: x² - 7x + 10 = 0
Factor: (x - 2)(x - 5) = 0
Solutions: x = 2 or x = 5

Example 5: Quadratic Formula
Equation: x² + 4x - 5 = 0, so a = 1, b = 4, c = -5
Discriminant: 16 + 20 = 36
x = (-4 ± 6) / 2
Solutions: x = 1 or x = -5

Check every answer by substituting it back into the original equation. If both sides match, you've got it right.

Other Maths Calculators

Explore all