Maths

Big Number Calculator

Add, subtract, multiply, divide and raise whole numbers of any length, exactly.

By Nitin Raturi · Last reviewed

Your numbers

How to use the Big Number Calculator

Do exact arithmetic on whole numbers too big for an ordinary calculator.

  1. Enter the first number.
  2. Choose the operation.
  3. Enter the second number.
  4. Read the exact answer, its digit count, and any remainder.

Good to know

  • Answers are exact; nothing is rounded.
  • Use Copy to take a long answer elsewhere.

First number

A whole number of any length, up to 5,000 digits.

How to fill it in

  • Type or paste digits; commas, spaces and underscores are ignored.
  • A minus sign in front makes it negative.

Example

Two 30-digit numbers multiply to a 60-digit answer.

Operation

What to do with the two numbers.

How to fill it in

  • Add, subtract, multiply, divide (quotient and remainder), power, or remainder (mod).

Example

2 to the power 100 is 12,67,65,06,00,22,82,29,40,14,96,70,32,05,376.

Second number

The other whole number: what you add, subtract, multiply or divide by, or the power.

How to fill it in

  • A power must be 0 or more, and the answer may have up to 1,00,000 digits.

Example

10²¹ ÷ 7 = 14,28,57,14,28,57,14,28,57,142 remainder 6.

Keep in mind: Division keeps whole numbers: it gives a quotient and a remainder, not decimals.

a × b

1,21,93,26,31,13,70,21,79,52,26,18,50,32,73,36,22,92,33,32,23,74,63,80,11,11,26,35,26,900

The exact answer has 60 digits.

Exact whole-number arithmetic. Division and remainder round towards zero; the remainder takes the sign of the first number.

How this calculator works

  1. Step 1Readevery digitNumbers are kept as exact whole numbers.
  2. Step 2Work+ − × ÷ ^ modThe operation runs on all the digits.
  3. Step 3Shownothing roundedThe full answer, grouped for reading.

Ordinary calculators keep about 15 to 16 significant digits and round the rest. This one keeps every digit, so long answers are exact.

Worked example: 2 to the power 100

2¹⁰⁰, exactly
Power
2 × 2 × … × 2 (100 times)
  1. Digits31
  2. Exact value12,67,65,06,00,22,82,29,40,14,96,70,32,05,376

A phone calculator shows about 1.2676506 × 10³⁰ and drops the rest.

Quotient and remainder

  • 10²¹ ÷ 714,28,57,14,28,57,14,28,57,142 r 6Whole-number division keeps a remainder.
  • Two 30-digit numbers ×60 digitsA product has about as many digits as both together.

For a negative first number, the remainder is negative too: −7 mod 2 is −1.

Assumptions and limits

  • Whole numbersNo decimals or fractions.
  • 5,000 digitsPer input; answers up to 1,00,000 digits.
  • Towards zeroDivision rounds towards zero.
  • No rootsSquare roots and logs are not supported.

Exact arithmetic keeps every digit. Factors and notation help make sense of huge results.

To break a large number into primes, use the prime factorization calculator, which works up to 10¹². For a compact approximate form, the scientific notation calculator writes it as a × 10ⁿ.

Common mistakes

  • Mistake: Trusting a phone calculator past 15 digits.

    Instead: Use exact arithmetic for long numbers.

  • Mistake: Expecting decimals from ÷.

    Instead: Read the remainder, or use long division.

  • Mistake: Raising to a huge power.

    Instead: Answers past 1,00,000 digits are refused.

Checking the method

A separate script re-works every golden value with Python's own exact integers.

Read how we test our calculators, or browse more maths calculators.

Frequently asked questions

What is 2 to the power 100?

12,67,65,06,00,22,82,29,40,14,96,70,32,05,376, a 31-digit number.

Why does my phone calculator give a different answer?

It keeps about 15 to 16 digits and rounds the rest; this keeps every digit.

How does division work?

It gives a whole quotient and a remainder: 10²¹ ÷ 7 = 14,28,57,14,28,57,14,28,57,142 remainder 6.

How many digits does the product of two 30-digit numbers have?

60 for the default example.

Can I paste numbers with commas?

Yes. Commas, spaces and underscores are ignored.

Sources and methodology

The formulas are standard time-value-of-money results. We check every figure against golden values worked out independently, by closed form and by month-by-month simulation; see the methodology.

Written and maintained by Nitin Raturi, a software engineer (about the author). Last reviewed 4 Nov 2026; next review due by . Found an error? Tell us.

Changelog

  • : Initial release.