← Math & statistics

Pi Digits Generator

Generate an exact decimal prefix of pi in your browser. Use digits mode when you want a specific length, or run the time challenge to see how many exact digits you can finish within one budget.

If you want to search inside the generated prefix, open Pi Digit Lab. If you want the learning-first version, return to Pi Approximation Explorer.

Other languages ja | en | zh-CN | es | pt-BR | fr
3 quick steps
  1. Choose exact digits mode for a fixed output length, or choose time challenge for a bounded run.
  2. Run a small preset first so you can confirm the display mode, copy flow, and TXT export.
  3. Open Pi Digit Lab when you want to search for one sequence, jump to an index, or copy only one selected span.
Mode

This page counts digits after the decimal point. The output always starts with 3..

Auto shows the full block up to 5,000 digits and switches to a head/tail preview above that point.

Digits after the decimal point

Generated digits
Elapsed ms
Chudnovsky terms
Status
Display

Output

No output yet.

How it works

This page uses a Chudnovsky-based exact-computation workflow in a worker so the browser stays responsive. Digits mode aims for a chosen decimal length, while time challenge walks through exact checkpoints and keeps the largest completed prefix.

FAQ

Does this page generate exact digits or only approximations?

It is designed to return a decimal string for the requested prefix, not a classroom estimate. That is why the page focuses on text output instead of a convergence chart.

What does first n digits mean here?

The input counts digits after the decimal point. If you enter 100, the result is 3. followed by 100 digits.

Why does the page switch to head and tail after 5,000 digits?

Rendering a huge text block is unnecessary for most sessions, so the page previews the beginning and the end by default while keeping the full text for copy and TXT export.

What is the time challenge mode?

Instead of promising every possible digit count, the page tries exact checkpoints in order and keeps the largest completed block reached within the chosen time budget.

What happens when I press stop?

The current job is cancelled immediately so the page stays responsive, and the last completed output remains available.

Related calculators