Math

Instant, private, and free

Power Modulo Calculator.

Calculate base^exponent modulo modulus exactly.

On-device calculationNo signup
01

Set your values

Results update as you type.

Remainder: 7

Remainder

0.000000

Results update automatically as you type.

Use Cases

Cryptography and RSA calculations

Modular exponentiation is a core operation in public-key cryptography, such as RSA encryption and decryption, where large numbers are used.

Example: Compute 5^13 mod 17 to simulate a simple RSA-style operation.

Programming and algorithm testing

When implementing algorithms that require modular arithmetic, quickly verify results without writing code.

Example: Check that (2^10) mod 1000 equals 24.

Frequently Asked Questions

What is modular exponentiation?
Modular exponentiation computes (base^exponent) mod modulus. Instead of calculating the huge power and then taking the remainder, it uses efficient algorithms to find the remainder directly, which is essential for large numbers.
How does the Power Modulo Calculator work?
You enter the base, exponent, and modulus. The calculator uses the method of exponentiation by squaring to compute the remainder efficiently, even for very large exponents, without overflow.
Can I use this for negative exponents?
This calculator is designed for non-negative integer exponents. For negative exponents, you would need modular inverse, which is not supported here.

Tips & Common Mistakes

Tips

  • Ensure the modulus is a positive integer. If it is zero, the result is undefined.
  • For large exponents, the calculator handles them efficiently, but you can still use it for small numbers to verify manual calculations.
  • Use this tool to check your own modular exponentiation implementations for correctness.
  • Remember that the result is always in the range 0 to modulus-1.

Common Mistakes to Avoid

  • Entering a negative exponent, which is not supported and will produce an error.
  • Using a modulus of 0, which is invalid because division by zero is undefined.
  • Confusing the order of operations: the calculator computes (base^exponent) mod modulus, not base^(exponent mod modulus).

Last updated: August 13, 2026