Skip to content

Perfect square and cube checker

Test one signed integer for exact square and cube roots without approximating a general root.

Enter an integer

Your data stays in this browser.

Use a signed base-10 integer up to 100 digits.

Perfect-power check

Enter an integer and choose Calculate.

How to check an integer

  1. Enter one signed whole number. Up to 100 digits are accepted, so the test does not depend on floating-point precision.
  2. Choose Calculate or press Enter. The page checks the square and cube properties independently.
  3. A Yes result includes the exact integer root. For a No result, the context value is the integer root taken toward zero; square-root context stays nonnegative.
  4. Editing the number clears every result and copy state. Clear removes the input while keeping this page focused on the same two tests.

Perfect-square and perfect-cube rules

An integer n is a perfect square when some integer k satisfies k² = n. Integer squares are never negative, so a negative input cannot be a perfect square over the real integers.

An integer n is a perfect cube when some integer k satisfies k³ = n. Negative values may be perfect cubes because the cube of a negative integer is negative.

The checker finds roots by exact integer comparisons, not Math.sqrt or a rounded decimal approximation. Zero and one are both perfect squares and perfect cubes.

Examples

A number that is both: 64

64 = 8² and 64 = 4³, so both checks return Yes with exact roots 8 and 4.

A negative cube: −125

No real integer squared equals −125, but (−5)³ = −125. The square result is No and the cube result is Yes.

Neither: 20

Four squared is 16 and five squared is 25; two cubed is 8 and three cubed is 27. Therefore 20 is neither a perfect square nor a perfect cube.

Limits and interpretation

Frequently asked questions

Is 1 a perfect square and cube?

Yes. It equals 1² and 1³.

Can a negative number be a perfect square?

Not among real integers, because multiplying an integer by itself cannot produce a negative value.

Can a negative number be a perfect cube?

Yes. For example, −27 = (−3)³.

Why not use a decimal root?

A rounded decimal can misclassify a large value. Exact integer multiplication confirms the identity.

Is this a general root calculator?

No. It answers only the integer perfect-square and perfect-cube questions.