Factorial Calculator
Calculate n! — the product of all positive integers up to n.
Calculate
Enter your values below.
Result
n!
0
Formula used
n! = n × (n−1) × (n−2) × … × 1
Example: 6! = 720.
How to use this calculator
- Enter n.
- Press Calculate to see your result instantly.
FAQ
Frequently asked questions
What is 0!?
By definition, 0! = 1.
Why is there a maximum of 170?
Beyond 170!, the result exceeds the largest number JavaScript can represent precisely.
What is factorial used for?
It's fundamental to permutations, combinations, and probability calculations.
Can I calculate the factorial of a negative number?
No — factorial is only defined for non-negative integers.
