Square Root Calculator: Simple Math Magic

Calculate square roots, cube roots, or any nth root of a number

How It Works

This calculator finds the root of any number. For square roots, it also shows the result in simplified radical form when possible.

  • Square root (√x): Find what number multiplied by itself equals x
  • Cube root (∛x): Find what number multiplied by itself three times equals x
  • nth root: Find what number raised to the power n equals x

Example: √8 = 2√2 ≈ 2.828

Worked example: simplifying a square root

Enter 12 with Square Root selected. The decimal result is Math.pow(12, 1/2) ≈ 3.464102, but the tool doesn't stop there — it also searches for the largest perfect-square factor of 12. Testing factors: 12 = 4 × 3, and 4 is a perfect square (2²). Pulling that out: √12 = √(4×3) = √4 × √3 = 2√3. Verify numerically: 2 × √3 = 2 × 1.7320508 = 3.4641016, matching the decimal result. If a number has no perfect-square factor at all (like 7 or 11), the tool leaves the radical unsimplified since there's nothing to pull out.

Worked example: cube root and custom nth root

Switch to Cube Root and enter 27: Math.pow(27, 1/3) = 3 exactly, since 3×3×3 = 27. Switch to Custom nth Root, enter 4 as the root value, and enter 16: Math.pow(16, 1/4) = 2, since 2×2×2×2 = 16.

How negative numbers are handled

An odd root of a negative number is well-defined in real numbers — the cube root of -8 is -2, because (-2)³ = -8 — and the calculator computes this correctly by working with the absolute value and reattaching the negative sign. An even root of a negative number (like the square root of -4) has no real solution, since no real number squared gives a negative result, so the tool returns an explicit error instead of NaN.

Precision

Decimal results are shown to 6 decimal places with trailing zeros trimmed. The simplified radical form is only computed for square roots (root = 2) of positive numbers — cube roots and other nth roots show the decimal approximation only.