Skip to calculator

Mathematics · Numbers and arithmetic

Raise a base to an exponent

Evaluate aᵇ. Integers, decimals, negative exponents (reciprocals), and 1/2 (square root, base ≥ 0) are possible, within the reals and floating-point limits.

Calculate

Real number. Negative only if the exponent is an integer.

Must be an integer if the base is negative. 0 to a negative power is rejected.

How the calculator works

The engine computes a ** b. If a < 0 and b is not an integer, the operation is refused (even roots of negatives would be complex). If a = 0 and b < 0, that is division by zero. Overflow to infinity is reported as out of range.

Formula and method

aᵇ = a × a × … × a    (b entier positif)

2¹⁰ = 1024. a⁰ = 1 for a ≠ 0. a⁻ⁿ = 1 / aⁿ (if a ≠ 0).

a^(1/2) = √a    (a ≥ 0)

9^0.5 = 3. (−2)^0.5 is rejected here.

Base and exponent are reals with the negative-base constraint. This is not a compound-interest calculator: (1+r)^n with a principal and optional deposits has its own page that starts from money and a rate.

Worked example

Power of two

base = 2, exponent = 10

  1. 2⁵ = 32.
  2. 2¹⁰ = 32 × 32 = 1024.

2¹⁰ = 1024.

Negative exponent

base = 5, exponent = −2

  1. 5² = 25.
  2. 5⁻² = 1/25 = 0.04.

0.04.

Input notes

Base (a)
The number being multiplied by itself (or inverted, or rooted). Zero is allowed for nonnegative exponents.
Exponent (b)
How many times, including fractions and negatives. Integer required when the base is negative.

Assumptions and limits

Assumptions

  • Real numbers only.
  • 0⁰ is treated as the floating-point convention of the runtime (typically 1 in JavaScript); do not treat that as a theorem.

Limits

  • No complex results.
  • Large exponents overflow.
  • Not an interest or APR engine.

How to read the result

1024 is 2 multiplied ten times. 0.04 is the reciprocal of 25. For money growing at a stated rate, the compound-interest page applies A = P(1+r/n)^{nt} with a compounding frequency.

Common mistakes

  • Reading aᵇ as a × b.

    2¹⁰ is 1024, not 20.

  • Taking (−8)^{1/3} here and expecting −2.

    A non-integer exponent with a negative base is refused. Cube roots of negatives are not implemented on this page.

Methodology · Sources

Related calculations

Frequently asked questions

Why is a negative base blocked for 0.5?

√ of a negative is not real. This tool stays on the reals.

Integer exponents on a negative base are fine: (−2)³ = −8. Half-exponents are square roots and are limited to a ≥ 0.

What is 5⁰?

1, for a nonzero base.

Any nonzero number to the power 0 is 1 by the usual empty-product convention used in this evaluation.

How do I model compound interest?

Use the compound-interest calculator, not a bare aᵇ, unless you already formed (1+r).

Interest needs a principal, a nominal rate, time, and a compounding frequency. The dedicated page also reports an effective annual rate.

Author and update

Written by Rédaction HexaCalc (editorial team). Content last updated: August 25, 2026. No third-party medical or financial review is claimed.

This calculation uses a standard mathematical identity. See also the methodology.

Money and compounding

If a is 1 plus a rate, and b is a number of periods, the interest tool labels the inputs as dollars, percent, and years.

Open compound interest

Category: Mathematics