A prime gap of length
is a run of
consecutive composite numbers between two successive
primes, where
is a positive integer.
Therefore, the difference between two successive primes
and
bounding a prime gap
of length
is
, where
is the
th prime number. Since the
prime difference function
|
(1)
|
is always even (except for ), all prime gaps
are also even. The notation
is commonly used to denote the smallest prime
corresponding to the start of a prime gap of length
,
i.e., such that
is prime,
,
,
...,
are all composite,
and
is prime
(with the additional constraint that no smaller number satisfying these properties
exists).
The maximal prime gap is the length of the largest prime
gap that begins with a prime
less than some maximum value
. For
, 2, ...,
is given by 4, 8, 20, 36, 72, 114, 154, 220, 282, 354,
464, 540, 674, 804, 906, 1132, ... (OEIS A053303).
Arbitrarily large prime gaps exist. For example, for any ,
the numbers
,
, ...,
are all composite (Havil
2003, p. 170). However, no general method more sophisticated than an exhaustive
search is known for the determination of first occurrences and maximal prime
gaps (Nicely 1999).
Writing
for the
-fold
nested logarithm, Ford et al. (2018) proved
the asymptotic lower bound
|
(2)
|
GPT 5.6 Sol (2026) claimed the stronger bound
|
(3)
|
an improvement by a factor of . The paper identifies
GPT 5.6 Sol as its author. Alexeev (2026) formalized the two main statements unconditionally
in Lean. After discussions with Terry Tao and James Maynard, Green (2026) reported
that he was "more or less convinced" that the result was correct. The manuscript
has not been refereed, and the correspondence between the manuscript and formalization
has not received independent review (VibeMathed 2026).
Cramér (1937) and Shanks (1964) conjectured that
|
(4)
|
Wolf conjectures a slightly different form
|
(5)
|
which agrees better with numerical evidence.
Wolf conjectures that the maximal gap between two consecutive primes
less than
appears approximately at
|
(6)
|
where is the prime
counting function and
is the twin primes constant. Setting
reduces to Cramer's conjecture for large
,
|
(7)
|
It is known that there is a prime gap of length 804 following , and a prime
gap of length
following
(Baugh and O'Hara 1992). H. Dubner (2001) discovered a prime
gap of length
between two 3396-digit probable primes. On Jan. 15,
2004, J. K. Andersen and H. Rosenthal found a prime
gap of length
between two probable primes of
digits each. In January-May 2004, Hans Rosenthal and Jens
Kruse Andersen found a prime gap of length
between two probable primes
with
digits each (Andersen 2004).
The average prime gap through is
for
and is asymptotic
to
by the prime
number theorem. This average grows without bound even
though bounded gaps occur infinitely often. The merit
of an individual prime gap compares it to this local
average scale, and is given by
. As of Oct. 2026,
the largest known merit for a gap between proven primes
is 42.5192, attained by a gap of length 59724 following a 611-digit prime
number and discovered by M. Vojvoda (Prime
Gap List Project 2026, Vojvoda 2026). A larger merit of 42.5402 is listed for a gap
of length 14282 between 146-digit probable primes
discovered by S. Troisi (Prime Gap List Project
2026). The primes preceding gaps of increasing record
merit begin 2, 3, 7, 113, 1129, 1327, 19609, ... (OEIS A111870).
Young and Potler (1989) determined the first occurrences of prime gaps up to , with all first occurrences found between
1 and 673. Nicely (1999) has extended the list of maximal prime gaps. The following
table gives the values of
for record gaps, namely gaps longer than every preceding prime gap (OEIS A005250
and A002386). As of Oct. 16, 2026, the
confirmed records extend through a gap of length 1854 following
(Andersen and Luhn 2026). First occurrences
of lengths that do not set a record, such as the gap of length 10 following 139,
are omitted.
| 1 | 2 | 490 | |
| 2 | 3 | 500 | |
| 4 | 7 | 514 | |
| 6 | 23 | 516 | |
| 8 | 89 | 532 | |
| 14 | 113 | 534 | |
| 18 | 523 | 540 | |
| 20 | 887 | 582 | |
| 22 | 588 | ||
| 34 | 602 | ||
| 36 | 652 | ||
| 44 | 674 | ||
| 52 | 716 | ||
| 72 | 766 | ||
| 86 | 778 | ||
| 96 | 804 | ||
| 112 | 806 | ||
| 114 | 906 | ||
| 118 | 916 | ||
| 132 | 924 | ||
| 148 | |||
| 154 | |||
| 180 | |||
| 210 | |||
| 220 | |||
| 222 | |||
| 234 | |||
| 248 | |||
| 250 | |||
| 282 | |||
| 288 | |||
| 292 | |||
| 320 | |||
| 336 | |||
| 354 | |||
| 382 | |||
| 384 | |||
| 394 | |||
| 456 | |||
| 464 | |||
| 468 | |||
| 474 | |||
| 486 |
Define
|
(8)
|
as the infimum limit of the ratio of the th prime difference to the
natural logarithm of the
th prime number. If there are
an infinite number of twin primes, then
.
This follows since it must then be true that
infinitely often, say at
for
, 2, ..., so a necessary
condition for the twin prime conjecture to
hold is that
|
(9)
| |||
|
(10)
| |||
|
(11)
| |||
|
(12)
|
However, this condition is not sufficient, since the same proof works if 2 is replaced by any constant.
Hardy and Littlewood showed in 1926 that, subject to the truth of the generalized Riemann hypothesis, . This was subsequently
improved by Rankin (again assuming the generalized
Riemann hypothesis) to
. In 1940, Erdős
used sieve theory to show for the first time with no assumptions that
.
This was subsequently improved to 15/16 (Ricci),
(Bombieri and Davenport 1966), and
(Pil'Tai 1972),
as quoted in Le Lionnais (1983, p. 26). Huxley (1973, 1977) obtained
,
which was improved by Maier in 1986 to
, which was the
best result known until 2003 (American Institute of Mathematics).
At a March 2003 meeting on elementary and analytic number theory in Oberwolfach, Germany, Goldston and Yildirim presented an attempted
proof that . While the original proof turned out to be flawed (Mackenzie 2003ab), the result
has now been established by a new proof (American Institute
of Mathematics 2005, Cipra 2005, Devlin 2005, Goldston et al. 2005ab).
Zhang (2014) subsequently proved the much stronger unnormalized result that the infimum limit is finite,
initially obtaining
. Work of Maynard
(2015) and the Polymath8 project then reduced the unconditional bound
to
(Polymath 2014). Thus infinitely
many pairs of consecutive primes differ by at most
246. This result on bounded gaps between
primes does not prove that a gap of exactly 2 occurs infinitely often, so it
does not prove the twin prime conjecture.
Assuming the Elliott-Halberstam conjecture gives the conditional bound (Maynard 2015). It also gives
(Polymath 2014), improving Maynard's earlier bound
. The stronger generalized
conjecture gives
and
(Polymath 2014). Neither conditional result proves
that
.
OpenAI (2026a) reported the stronger maximal-gap lower bound
|
(13)
|
where
again denotes the
-fold
nested natural logarithm. GPT-6 Astra discovered
the proof. VibeMathed's September verification replayed
the Lean proof and checked its axioms, but independent
mathematical review of the new argument had not been reported as of Sep. 7,
2026.
Mossinghoff and Trudgian (2026) call a consecutive-prime gap frangible when every integer
strictly between its endpoints has a least prime
factor strictly less than the gap
. This is the property
in Erdős problem 682. Assuming the Dickson-Hardy-Littlewood
prime-tuples conjecture, the number
of such gaps with left endpoint
satisfies
|
(14)
|
where . The constant bounds are rigorous,
while the counting asymptotic is conditional (Mossinghoff and Trudgian 2026).