Quadratic Equation Solver
Real or complex roots of ax² + bx + c = 0, with the discriminant shown.
🔒 Runs entirely in your browser — nothing here is ever uploaded
About the Quadratic Equation Solver
Solves any quadratic equation ax² + bx + c = 0 for x, using the quadratic formula, and reports whether the roots are two distinct real numbers, one repeated real number, or a complex conjugate pair, depending on the discriminant.
- Enter the coefficients a, b, and c from your equation in the form ax² + bx + c = 0.
- Read the roots in the result panel, along with the discriminant.
For x² − 5x + 6 = 0 (a=1, b=−5, c=6): discriminant = (−5)² − 4(1)(6) = 25 − 24 = 1, which is positive, giving two real roots: x = 3 and x = 2.
| Discriminant (b²−4ac) | Root Type | Example |
|---|---|---|
| > 0 | Two distinct real roots | x²−5x+6=0 → x=2, 3 |
| = 0 | One repeated real root | x²−4x+4=0 → x=2 |
| < 0 | Two complex conjugate roots | x²+x+1=0 → x=−0.5±0.866i |
If a = 0, the equation isn't actually quadratic — it reduces to a linear equation (bx + c = 0), or, if b is also 0, either an identity (always true, if c = 0 too) or a contradiction (never true). The calculator detects these edge cases and explains them rather than silently dividing by zero.
- • A positive discriminant always means two distinct real roots; check its sign first to know what kind of answer to expect before looking at the roots themselves.
- • A discriminant of exactly 0 means the parabola touches the x-axis at exactly one point (a repeated root) — the vertex sits exactly on the axis.
- • Complex roots always come in conjugate pairs (real ± imaginary·i) for a quadratic with real coefficients — you'll never get just one complex root alone.
- Khan Academy — The quadratic formula and its derivation from completing the square — accessed 2026-08-30