Math · Algebra
Quadratic formula calculator.
Enter a, b and c from ax² + bx + c = 0. You get the discriminant, both roots (real or complex), the vertex and every step. Everything runs in your browser.
x² − 3x − 4 = 0 has discriminant (−3)² − 4(1)(−4) = 25, which is positive, so there are two real roots: x = 4 and x = −1. The vertex is at (1.5, −6.25).
Your numbers
Your result
Fill the form and press Calculate.
The formula
For a quadratic equation ax² + bx + c = 0 (a ≠ 0) the solutions are x = (−b ± √(b² − 4ac)) / (2a). The expression under the root, D = b² − 4ac, is the discriminant. If D is positive there are two distinct real roots, if D is 0 there is one repeated real root, and if D is negative the two roots are complex conjugates and the parabola never crosses the x-axis.
The vertex of the parabola y = ax² + bx + c is at x = −b / (2a), and y is found by substituting that x back in. The parabola opens upward when a is positive (the vertex is a minimum) and downward when a is negative (a maximum).
Worked example
x² − 3x − 4 = 0: a = 1, b = −3, c = −4. D = 9 + 16 = 25, √25 = 5, so x = (3 ± 5) / 2, giving x = 4 and x = −1. The vertex is x = 3 / 2 = 1.5, y = −6.25. For 2x² + 4x + 5 = 0 the discriminant is 16 − 40 = −24, so there are no real roots; the complex roots are x = −1 ± 1.224745i.
Limits
This calculator handles real coefficients only. Exact forms with square roots are shown when a, b and c are whole numbers; decimal coefficients give decimal answers. Check any answer by substituting it back into the equation.
Sources, opened 15 October 2026: OpenStax, Algebra and Trigonometry 2e, 2.5 Quadratic Equations (quadratic formula; discriminant and real versus complex solutions).
Frequently asked questions
How do you use the quadratic formula?
Write the equation as ax² + bx + c = 0, read off a, b and c, compute the discriminant b² − 4ac, then x = (−b ± √discriminant) / 2a. For x² − 3x − 4 = 0 that gives x = 4 and x = −1.
What does the discriminant tell you?
A positive discriminant means two distinct real roots, zero means one repeated real root, and a negative discriminant means two complex conjugate roots with no real solution.
Can the quadratic formula give complex roots?
Yes. When b² − 4ac is negative the square root is imaginary, so the roots are written as a real part plus or minus an imaginary part, such as −1 ± 1.224745i for 2x² + 4x + 5 = 0.
What if a is 0?
Then the equation is linear, not quadratic, and has a single solution x = −c / b. The calculator tells you this instead of dividing by zero.
How do I find the vertex of a parabola?
The x-coordinate of the vertex is −b / (2a). Substitute it into ax² + bx + c to get the y-coordinate. For x² − 3x − 4 the vertex is (1.5, −6.25).
Learning aid
Educational calculator with worked steps. Check answers and the required method against your own course or textbook. Nothing you type leaves your browser.