Fibonacci Sequence Calculator

Compute the nth Fibonacci number, generate a sequence of terms, explore golden ratio convergence, Binet's formula, presets, sequence table, and ratio convergence visual.

Max 300
Default 0 (use 2 for Lucas)
Default 1
F(20)
6,765
The 20th term of the sequence using iterative computation
Golden Ratio (φ)
1.6180339887
φ = (1 + √5) / 2 ≈ 1.6180339887 — the limit of consecutive Fibonacci ratios
F(20)/F(19) Ratio
1.6180339632
Error from φ: 2.5583e-8
Sum of All Terms
17,710
Sum of F(0) through F(20). For standard Fibonacci, sum = F(n+2) − 1
Total Terms
21
21 terms generated (indices 0 through 20)
Sequence Type
Standard Fibonacci
Starting with F(0) = 0, F(1) = 1

Ratio Convergence to φ

Bar height = deviation from φ. Green = converged (<0.01), Blue = close, Orange = far.

Sequence Table

IndexValueRatio F(n)/F(n-1)Digits
001
111
211.000000001
322.000000001
431.500000001
551.666666671
681.600000001
7131.625000002
8211.615384622
9341.619047622
10551.617647062
11891.618181822
121441.617977533
132331.618055563
143771.618025753
156101.618037143
169871.618032793
171,5971.618034454
182,5841.618033814
194,1811.618034064
206,7651.618033964
Notable Fibonacci Numbers
nF(n)DigitsF(n)/F(n-1)
111
2111.00000000
3212.00000000
5511.66666667
82121.61538462
105521.61764706
1561031.61803714
206,76541.61803396
2575,02551.61803399
30832,04061.61803399
40102,334,15591.61803399
5012,586,269,025111.61803399
Planning notes, formulas, and examples

About the Fibonacci Sequence Calculator

The **Fibonacci Sequence Calculator** is a comprehensive tool for exploring the world's most famous number sequence. Enter any positive integer n to compute the nth Fibonacci number, generate a full sequence of terms, and see how consecutive ratios converge toward the golden ratio φ ≈ 1.6180339887.

The Fibonacci sequence begins with 0 and 1, and each subsequent term is the sum of the two preceding terms: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, and so on. This deceptively simple rule produces a sequence with extraordinary mathematical properties. The ratio of consecutive terms approaches the golden ratio, the sum of the first n terms equals F(n+2) − 1, and every positive integer can be written as a sum of non-consecutive Fibonacci numbers (Zeckendorf's theorem).

This calculator supports multiple computation methods. The iterative approach generates all terms up to n, while Binet's closed-form formula uses φ (the golden ratio) and ψ (its conjugate) to compute F(n) directly — though floating-point precision limits its accuracy for very large n. You can also set custom starting values to explore generalized Fibonacci-like sequences (Lucas numbers, for instance, start with 2 and 1).

A detailed sequence table lists each term with its index, value, and the ratio to the previous term. The ratio convergence chart visually demonstrates how quickly the ratios approach φ. Preset buttons let you jump to notable values like F(10) = 55, F(20) = 6765, or F(50) = 12,586,269,025. Whether you are studying number theory, exploring spirals in nature, or just curious about this iconic sequence, this page gives you the sequence details and convergence context in one place.

When This Page Helps

Computing dozens of Fibonacci terms by hand introduces cumulative errors and is painfully slow — missing one addition cascades through every subsequent value. This calculator generates up to 300 terms, showing the golden-ratio convergence at every step so you can see how quickly F(n)/F(n−1) approaches φ. It also supports custom seed values for Lucas numbers and other generalised sequences, and compares iterative versus Binet's closed-form results so you can understand where floating-point precision breaks down.

How to Use the Inputs

  1. Enter how many Fibonacci terms to generate.
  2. Optionally change the first two seed values (default 0 and 1).
  3. Select the computation method: iterative or Binet's formula.
  4. Click a preset to jump to a famous Fibonacci number.
  5. Review output cards for the nth term, golden ratio, sum, and more.
  6. Browse the sequence table to see each term and its ratio to the previous.
  7. Examine the convergence chart to see how ratios approach φ.
Formula used
F(n) = F(n-1) + F(n-2), with F(0) = 0, F(1) = 1. Binet: F(n) = (φⁿ − ψⁿ) / √5 where φ = (1+√5)/2, ψ = (1−√5)/2.

Example Calculation

Result: 10: F(10) = 55

For n = 10: F(10) = 55. The sequence is 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55. The ratio F(10)/F(9) = 55/34 ≈ 1.6176, close to φ ≈ 1.6180.

Tips & Best Practices

  • Check that all inputs use the same scale and assumptions before trusting the result.
  • Compare the answer with the worked example or a rough estimate to catch entry mistakes.

The Golden Ratio Connection

The ratio of consecutive Fibonacci numbers F(n+1)/F(n) converges to the golden ratio φ = (1 + √5) / 2 ≈ 1.618034. This convergence is exponentially fast — by n = 12, the ratio already matches φ to five decimal places. Binet's closed-form formula F(n) = (φⁿ − ψⁿ)/√5 (where ψ = 1 − φ) makes this relationship explicit, though floating-point limits mean the iterative method is more reliable for large n in practice.

Fibonacci Numbers in Nature and Computer Science

Sunflower heads, pinecone spirals, and leaf phyllotaxis follow Fibonacci counts because the golden angle (≈ 137.5°) produces the most efficient packing. In computer science, Fibonacci numbers appear in the analysis of the Euclidean algorithm (worst-case input is consecutive Fibonacci numbers), Fibonacci heaps, and optimal binary search trees. The sequence also defines Zeckendorf's representation, where every positive integer can be written as a sum of non-consecutive Fibonacci numbers.

Generalised Sequences — Lucas, Tribonacci, and Beyond

Changing the seed values from (0, 1) produces different but related sequences. Seeds (2, 1) give the Lucas numbers, which share many properties with Fibonacci numbers and satisfy L(n) = F(n−1) + F(n+1). Extending the recurrence to three terms (T(n) = T(n−1) + T(n−2) + T(n−3)) produces the Tribonacci sequence, whose ratio converges to the Tribonacci constant ≈ 1.8393. Use this calculator's custom seed feature to explore any of these families.

Sources & Methodology

Last updated:

Frequently Asked Questions

  • A sequence where each number is the sum of the two preceding ones, starting from 0 and 1: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34,...