Want a Custom tool for Yourself?

Need a Custom Tool? We build custom tools that can save hours per employee per day.

Completing The Square Calculator

Complete the square for ax²+bx+c: enter a, b, c and get the vertex form, helpful for solving quadratics and graphing parabolas.

Enter the Details

We will solve the quadratic equation ax2 + bx + c = 0. Enter your respective coefficients:


Result will appear here...


Last updated: April 28, 2026

Created by: Eon Tools Dev Team

Reviewed by: Okan Atalay



What this calculator does

So, you have a quadratic ax2 + bx + c = 0 and you want its solutions. This tool finds them from the coefficients a, b, and c, using the approach it is named for: completing the square. It returns the values of x, whether they are two real numbers, one repeated value, or a complex pair, and a precision box sets the decimal places.

The method behind it, completing the square, is worth knowing in its own right, because it is where the quadratic formula comes from and how the vertex of a parabola is found.

How to use it

  1. Enter coefficients a, b, and c.
  2. Optionally set the precision, the number of decimal places (it starts at 2).
  3. Press Calculate.

The coefficient a cannot be zero, since without an x2 term there is no square to complete.

The method: completing the square

Completing the square is a way of forcing a quadratic into a perfect-square shape. The trick rests on one pattern: x2 + bx is almost a perfect square. The square (x + b/2)2 expands to x2 + bx + (b/2)2, which is what you have plus the single extra term (b/2)2. So if you add that term, and subtract it again to keep things balanced, the awkward x2 + bx turns into a tidy squared bracket with a constant left over.

This is one of the oldest methods in algebra. Around 820, al-Khwarizmi set it out with literal geometric squares, completing an actual square figure to solve the equation, in the very book that gave us the word algebra.

How it reaches the solutions

For ax2 + bx + c = 0, you divide through by a, complete the square on what remains, and arrive at

(x + b/2a)2 = (b2 - 4ac) / (4a2)

Take the square root of both sides, move the b/2a across, and you land on x = ( -b ± √(b2 - 4ac) ) / (2a). That is the quadratic formula, arrived at with nothing more than completing the square. In other words, the formula is not a separate piece of magic; it is this method done once, in general. The tool applies the same reasoning to your particular a, b, and c and reports the resulting solutions, in the same three cases the discriminant b2 - 4ac decides: two real, one repeated, or a complex pair.

A worked example, step by step

Solve x2 + 6x + 5 = 0.

  • Half of the 6 is 3, and 3 squared is 9. Add and subtract it: x2 + 6x + 9 - 9 + 5 = 0.
  • The first three terms are a perfect square: (x + 3)2 - 4 = 0.
  • So (x + 3)2 = 4, and taking the square root gives x + 3 = ±2.
  • Therefore x = -1 or x = -5.

The perfect-square step is the whole idea: once the equation reads (something)2 = a number, a square root finishes it.

Where completing the square also turns up

Solving is only half of what this method is good for. Completing the square is exactly how you rewrite a quadratic y = ax2 + bx + c into vertex form, y = a(x - h)2 + k, which displays the vertex of its parabola directly as the point (h, k). So the same move that solves the equation also locates the turning point of the curve, its highest or lowest value. If that is what you are after, the vertex form calculator does the conversion, and the parabola calculator maps the whole curve.

Questions people ask

What does completing the square mean?

Rewriting a quadratic as a perfect square plus a constant, by adding and subtracting the right term. Once it is a square equal to a number, a square root solves it.

Does the tool show every squared step?

It returns the solutions to your equation. The method described here is how those solutions are reached, so you can follow the same steps by hand on any quadratic.

Why learn this if the formula exists?

Because the formula is completing the square done in general, so the method explains where the formula comes from, and it is also how you find vertex form and the vertex.

Does it handle complex solutions?

Yes. When b2 - 4ac is negative, the square root step gives a complex pair, and the tool reports them.

Why can't a be zero?

Because with no x2 term there is no square to complete, and the equation is linear rather than quadratic.

References

On the method and its origins. Completing the square is the technique from which the quadratic formula is derived, and it was treated geometrically by al-Khwarizmi around 820, with related rules given even earlier.

  1. "Completing the Square: the prehistory of the quadratic formula," American Mathematical Society Feature Column, on the method as developed by Diophantus, Brahmagupta, and al-Khwarizmi.
  2. Eric W. Weisstein, "Quadratic Equation," from MathWorld, a Wolfram resource, on completing the square as a route to the quadratic formula.


Okan Atalay

Okan Atalay is a results driven senior operations manager and a graduate of Industrial Engineering from Bilkent University. With over 22 years of experience in textile manufacturing and integrated operations, he has led large scale business process improvements and strategic planning initiatives. Currently, he serves as a top mathematics expert for a global ed tech platform, where he applies his analytical expertise to solve complex mathematical problems. At Eon Tools, he reviews converter and maths tools.