Beginner

Factorial Calculator

Compute the factorial (n!) of a non-negative integer.
A non-negative whole number.
n!
3,628,800
n
10
Exact?
Yes
Factorial growth: 0! up to n!
Step by step
  1. 1

    Multiply all integers from 1 to n

    1 × 2 × 3 × 4 × 5 × 6 × 7 × 8 × 9 × 10
  2. 2

    10!

    3,628,800
Results are estimates for general information only and are not professional advice — always verify important results independently before relying on them. Read the full disclaimer.
Formula
n! = n × (n − 1) × … × 2 × 1, with 0! = 1
How this is calculated

The single input n must be a non-negative whole number (0, 1, 2, …); it represents how many items you are arranging. The factorial n! is defined as the product of every integer from 1 up to n, so the calculator starts with a running total of 1 and multiplies it by 2, then 3, and so on up to n. For example 5! = 1 × 2 × 3 × 4 × 5 = 120. The empty product gives 0! = 1 by convention, which keeps permutation and combination formulas consistent.

Factorials are pure counts, so there are no units, rates, or rounding factors involved. The result is computed iteratively in order, which avoids recursion limits but inherits the limits of the number format.

Two edge cases are handled explicitly. Negative numbers and non-integers are rejected, since the basic factorial is only defined on non-negative integers. Because results are stored as double-precision floating point (maximum about 1.8 × 10³⁰⁸), any value above 170! overflows to infinity and is flagged. Results up to 18! are exact integers; between 19! and 170! they are accurate floating-point approximations that may lose the least-significant digits.

About this calculator

The factorial of a non-negative integer n, written n!, is the product of every whole number from 1 up to n. By definition 0! = 1. Factorials grow extremely fast and appear throughout combinatorics, probability, and series expansions.

This calculator multiplies the terms iteratively. Because standard floating-point numbers cap out around 1.8 × 10³⁰⁸, factorials above 170! overflow to infinity and are flagged. Results below 18! are exact integers; larger values are accurate floating-point approximations.

Frequently asked questions

There is exactly one way to arrange zero items (the empty arrangement), and defining 0! = 1 keeps formulas for permutations and combinations consistent.

171! is larger than the maximum value a double-precision number can hold, so it overflows to infinity. 170! is the largest factorial representable as a finite number.

They count the number of ways to arrange items (permutations) and appear in combinations, probability, and Taylor series in calculus.

Also known as

n factorial
compute factorial
factorial of a number
n!
factorial

APA

TG we-Calculate Editorial Team. (2026). Factorial Calculator [Online calculator]. TG we-Calculate. https://we-calculate.com/calculator/factorial-calculator

Chicago

TG we-Calculate Editorial Team. "Factorial Calculator." TG we-Calculate. 2026. https://we-calculate.com/calculator/factorial-calculator.

IEEE

TG we-Calculate Editorial Team, "Factorial Calculator," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/calculator/factorial-calculator

BibTeX

@misc{wecalculate_factorial_calculator, title = {Factorial Calculator}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/calculator/factorial-calculator}}, year = {2026}, note = {TG we-Calculate} }

Did this calculator help you?