Factorial Calculator
Enter any non-negative integer from 0 to 1000 and get n!, the product of every positive integer up to and including n. The calculator uses arbitrary-precision arithmetic, so values like 100! (158 digits) or 1000! (2568 digits) are returned exactly, not truncated. Useful for combinatorics homework, permutation counts, probability derivations and anywhere a recursion boils down to a factorial term.
How to compute a factorial
-
1
Enter n
Type the non-negative integer you want the factorial of. By convention, `0! = 1`.
-
2
Get the exact value
The result appears as a full-precision integer, even for hundreds of digits.
-
3
Check the digit count
For very large values, the digit count below the result shows the magnitude at a glance; `1000!` runs to 2,568 digits.
-
4
Copy for your calculation
Copy the exact integer into your notes, a spreadsheet or another tool.
Factorial reference and growth
Factorials grow faster than any exponential. Below is the usual cheat sheet showing how quickly the value explodes and where IEEE-754 double precision runs out.
Small values
| n | n! |
|---|---|
| 0 | 1 |
| 1 | 1 |
| 5 | 120 |
| 10 | 3,628,800 |
| 13 | 6,227,020,800 |
| 20 | 2,432,902,008,176,640,000 |
Overflow boundaries
- 32-bit signed int: overflows at
13!(max value ~2.1 billion;12! = 479,001,600is the last that fits,13! = 6,227,020,800does not). - 64-bit signed int: overflows at
21!(20!is the last one that fits). - IEEE-754 double: becomes inexact at
22!;170!is the largest finite double.
Stirling’s approximation
For large n, Stirling gives a useful closed-form estimate:
n! ≈ √(2πn) · (n/e)^n
With n = 100, Stirling returns 9.3248 x 10^157, less than 0.1% off the exact 100!. Use it when a precise integer is not required and you only need order-of-magnitude reasoning.
Common uses
- Permutations: arrangements of
ndistinct items in order =n!. - Combinations:
C(n, k) = n! / (k! (n - k)!). - Probability: the denominator of many discrete distributions.
- Series: Taylor expansions, where coefficients include factorial terms.
Edge cases
0! = 1by convention (empty product). This is not a limit; it is a definition that makes combinatorial formulas consistent.- Negative integers and non-integers do not have a factorial in the elementary sense; the Gamma function extends the idea:
Γ(n+1) = n!for non-negative integers.
Frequently Asked Questions
The calculator accepts n from 0 to 1000. The largest input, 1000!, has 2,568 digits and is computed instantly. Values above 1000 are clamped to the cap.
It is a convention chosen so that formulas like nCk = n! / (k!(n-k)!) stay correct when k = 0 or k = n. It is also the value of the empty product, which is the multiplicative identity.
This tool focuses on the discrete factorial. For non-integer arguments you need the Gamma function; many science libraries expose Γ(n) and Γ(n+1) = n! on integers, letting you extend factorials to the reals.
No. The calculator does not store your number in a database and does not use it for anything beyond computing the factorial. In the multi-step view the value is carried in the page link so the results step can display it.
Related Tools
BMI Calculator
Calculate body mass index from height and weight. Shows WHO category, healthy-weight range and limitations of BMI.
Social Security Calculator
Estimate a US Social Security retirement benefit from your PIA and claiming age. Compare monthly and annual amounts at 62, FRA 67 and 70.
Age Calculator
Calculate exact age in years, months and days from a birth date, plus total days, hours and the next birthday countdown.
Dog Age Calculator
Convert your dog's age to human years using modern veterinary research. Breed-size aware: small, medium and large dogs age differently.
Amp-Hour Calculator
Work out battery runtime and stored energy from amp-hours, voltage and load current. Get runtime in hours and minutes plus energy in watt-hours and kilowatt-hours.
Fahrenheit to Celsius Converter
Convert Fahrenheit temperatures to Celsius with the exact formula, Kelvin output and common reference points for weather, cooking and health.
Tool available in other languages
- حاسبة المضروب [AR]
- Calculadora de Factorial [ES]
- 阶乘计算器 [ZH]
- Máy tính giai thừa [VI]
- 階乗計算機 [JA]
- Calculateur de Factorielle [FR]
- Fakultetsberäknare [SV]
- Calculadora de Fatorial [PT]
- เครื่องคำนวณแฟกทอเรียล [TH]
- Faculteitscalculator [NL]
- 팩토리얼 계산기 [KO]
- Kalkulator silni [PL]
- Faktöriyel Hesaplayıcı [TR]
- Fakultätsrechner [DE]
- Kalkulator Faktorial [ID]
- Calcolatore di fattoriali [IT]
- Калькулятор факториала [RU]