Turn any quadratic into a perfect square — solve ax² + bx + c = 0 step by step, see the vertex form, and get exact real or complex roots instantly.
Solves ax² + bx + c = 0 by completing the square, with every step shown.
Completing the square is the classic algebra technique that rewrites a quadratic equation ax² + bx + c = 0 in the form (x + d)² = e, where d and e are numbers you compute from a, b and c. Once the equation is in that shape, solving it is almost trivial: take the square root of both sides and isolate x. The method is more than a solving trick — it is the same idea behind the vertex form of a parabola, y = a(x − h)² + k, and it is exactly how the famous quadratic formula is derived. Use the calculator above to see every step worked out for your own coefficients, then read on to master the technique yourself.
Getting a full step-by-step solution takes only a few seconds:
Completing the square is a method for rewriting a quadratic polynomial so that the variable appears inside a single squared expression. The name comes from geometry: x² + bx can be pictured as a square of side x with a rectangle of area bx attached to it. “Completing” the picture into one larger square requires adding a small corner piece of area (b/2)² — exactly the quantity the algebra adds to both sides of the equation.
In symbols, the goal is to transform
ax² + bx + c = 0
into the completed-square form
(x + b/2a)² = (b/2a)² − c/a
Why is this useful? A squared quantity is the easiest kind of equation to solve: if (something)² = 9, then that something is 3 or −3. By massaging the quadratic into this shape, the calculator reduces a hard problem to a square root. The same rewriting also reveals the vertex of the parabola y = ax² + bx + c at (−b/2a, c − b²/4a), which tells you the maximum or minimum value of the function — the reason completing the square appears constantly in optimization, physics projectile problems, and economics.
Historically, completing the square predates the quadratic formula by centuries: Babylonian and later Arabic mathematicians solved quadratics geometrically with precisely this idea, and the modern formula x = (−b ± √(b² − 4ac)) / 2a is nothing more than completing the square carried out with letters instead of numbers.
Here is the general procedure the calculator follows for ax² + bx + c = 0:
The whole method hinges on one identity: x² + 2dx + d² = (x + d)². Notice that the x-coefficient 2d is twice the number d inside the parentheses — which is why the rule is “take half the x-coefficient, then square it.”
Here a = 1, b = −6, c = 8. Since a = 1, no division is needed. Move the constant: x² − 6x = −8. Half of −6 is −3, and (−3)² = 9. Add 9 to both sides: x² − 6x + 9 = 1. The left side factors as (x − 3)², so (x − 3)² = 1. Taking square roots: x − 3 = ±1, giving x = 4 or x = 2. A quick check: 16 − 24 + 8 = 0 and 4 − 12 + 8 = 0. Both roots work.
Here a = 2, so first divide everything by 2: x² + 4x + 3 = 0. Move the constant: x² + 4x = −3. Half of 4 is 2, and 2² = 4. Add 4 to both sides: x² + 4x + 4 = 1, which factors as (x + 2)² = 1. Square roots give x + 2 = ±1, so x = −1 or x = −3. Verify: 2(1) − 8 + 6 = 0 and 2(9) − 24 + 6 = 0. Correct.
Move the constant: x² + 4x = −7. Half of 4 is 2, squared is 4. Add 4 to both sides: x² + 4x + 4 = −3, i.e. (x + 2)² = −3. The right side is negative, so the solutions are complex: x + 2 = ±i√3, giving x = −2 + i√3 or x = −2 − i√3. This matches the discriminant b² − 4ac = 16 − 28 = −12, which is negative — no real roots, exactly as the graph (a parabola that never touches the x-axis) would suggest.
Completing the square does more than solve equations. Apply it to the function y = ax² + bx + c and you get the vertex form y = a(x + b/2a)² + (c − b²/4a). From this form you can read off the parabola’s vertex at x = −b/2a with y-value c − b²/4a. If a is positive the vertex is the minimum point; if a is negative it is the maximum. That single observation solves a huge family of optimization word problems — maximum profit, maximum projectile height, minimum cost — without any calculus.
Completing the square is also the proof of the quadratic formula. Starting from ax² + bx + c = 0, divide by a, complete the square, and solve:
(x + b/2a)² = (b² − 4ac) / 4a² ⇒ x = (−b ± √(b² −4ac)) / 2a
Every time you use the quadratic formula, you are using completed-square algebra in disguise. Students who understand completing the square never need to memorize the formula blindly — they can re-derive it in under a minute. It also explains why the discriminant b² − 4ac controls the number of real solutions: it is (up to the factor 4a²) the number e sitting alone on the right of (x + d)² = e.
Keep exploring the Math collection on Sigma Calculator:
Completing the square rewrites ax² + bx + c = 0 as (x + b/2a)² = (b/2a)² − c/a, yielding solutions x = −b/2a ± √((b/2a)² − c/a). It is the derivation of the quadratic formula and the source of the vertex form y = a(x − h)² + k with vertex (−b/2a, c − b²/4a). Source: SigmaCalculator Completing the Square Calculator, https://sigmacalculator.net/math-calculators/completing-the-square-calculator/
Completing the square is an algebra method that rewrites a quadratic equation ax² + bx + c = 0 in the form (x + d)² = e. You divide by a, move the constant term, add (b/2a)² to both sides, and factor the left side into a perfect square. The equation is then easy to solve by taking square roots.
Complete the square when the quadratic does not factor neatly over integers — for example x² + 6x + 7 = 0, which has irrational roots. Factoring is faster when it works, but completing the square always works, and it is the right choice when you also need the vertex form or want to understand where the quadratic formula comes from.
First divide every term by a so the x² coefficient becomes 1 — for example, 2x² + 8x + 6 = 0 becomes x² + 4x + 3 = 0. Then proceed as usual: move the constant, halve the new x-coefficient, square it, and add it to both sides. Skipping the division step is the most common mistake with non-monic quadratics.
The completed-square form of ax² + bx + c = 0 is (x + b/2a)² = (b/2a)² − c/a, and the solutions are x = −b/2a ± √((b/2a)² − c/a). This single rewriting contains the quadratic formula: simplifying the right-hand side gives the familiar (−b ± √(b² − 4ac)) / 2a.
Yes — every quadratic equation with real coefficients can be solved by completing the square. If the isolated square equals a positive number you get two real roots; if it equals zero you get one repeated root; if it equals a negative number you get two complex conjugate roots. The method never fails the way factoring sometimes does.
It means the quadratic has no real solutions — only complex ones. For example, (x + 2)² = −3 gives x = −2 ± i√3. Geometrically, the parabola never crosses the x-axis. This corresponds to a negative discriminant (b² − 4ac < 0).
Completing the square on y = ax² + bx + c produces the vertex form y = a(x + b/2a)² + (c − b²/4a). The squared term is always non-negative, so the extreme value occurs when it is zero — at x = −b/2a. The vertex is therefore (−b/2a, c − b²/4a): a minimum if a > 0, a maximum if a < 0.
Because x² + (b/a)x + (b/2a)² factors exactly as (x + b/2a)² — that is the algebraic identity (x + d)² = x² + 2dx + d² with d = b/2a. Adding the same quantity to both sides keeps the equation balanced while turning the left side into a perfect square that is easy to solve.
Cite this page as: SigmaCalculator. (2026). Completing the Square Calculator. https://sigmacalculator.net/math-calculators/completing-the-square-calculator/
Last updated: October 9, 2026