All users will need to merge their Minecraft Forum account with a new or existing Twitch account starting October 23rd. You can merge your accounts by clicking here. Have questions? Learn more here.

These are the largest single cave systems that can generate in 1.6.4 and earlier (at least back to InfDev) and 1.7 and later, as seen below sea level and layer 20, the latter layer chosen since it makes it easier to see variations in cave density. I modified the code to make cave systems always generate at the maximum size and 16 chunks apart for reasons that will be seen below:

Here is a look at one of the 1.6.4 cave systems in-game (I modified terrain to be like a Superflat world without any decoration):

The 1.6.4 cave systems contain 156 tunnels and 39 circular rooms while the 1.7 cave systems contain 56 tunnels and 14 circular rooms; in each case the number of tunnels is 4 times the number of circular rooms since when one is generated 0-3 additional tunnels are added to an otherwise single tunnel as seen in this simplified code example:

int size = rand.nextInt(rand.nextInt(rand.nextInt(maxSize) + 1) + 1);
for (int i = 0; i < size; ++i)
{
int tunnels = 1;
if (rand.nextInt(4) == 0)
{
tunnels += rand.nextInt(4);
generateCircularRoom();
}
for (int j = 0; j < tunnels; ++j)
{
generateTunnel();
}
}

"maxSize" is 40 for 1.6.4 and 15 for 1.7, which give a maximum size of 39 and 14 respectively (nextInt() returns a value between 0 and n-1), and with each iteration of the main loop there is a 25% chance of adding a circular room, which in turn has an additional 25% chance of adding 3 additional tunnels for a maximum of 4 generated from the same spot (each iteration also sets the starting coordinates of each room/tunnel(s) to random values between 0-15 for x and z (relative to the center chunk) and 0-126 for the y-coordinate).

Since there is a 25% chance of a circular room per iteration and a 25% chance of 4 tunnels this means that there is a 25% * 25% = 6.25% chance per iteration of the maximum number of tunnels. For a cave system with a size of 1 this means there is a 1 in 16 chance of 4 tunnels, for a size of 2 a one in 256 chance of 8 tunnels (6.25% ^ 2), for a size of 3 a one in 4096 chance of 12 tunnels, and so on until you reach the maximum sizes of 39 or 14.

For a size 39 cave system to have 156 tunnels the chance is (25% * 25%) ^ 39 = 1.1 x 10^-47 or one in 9.13 x 10^46.

For a size 14 cave system to have 56 tunnels the chance is (25% * 25%) ^ 14 = 1.4 x 10^-17 or one in 9.13 x 10^16.

However, that is not all - the chance of the maximum size being chosen is (maxSize ^ 3) or one in 64000 for 1.6.4 and one in 3375 for 1.7, and the chance of a chunk having a cave system (including a size of 0) is one in 15 in 1.6.4 and one in 7 in 1.7 for a combined chance of one in 960000 for 1.6.4 and one in 23625 for 1.7.

When combined with the above this results in a one in 8.8 x 10^52 chance of the largest possible cave system in 1.6.4 and a one in 1.7 x 10^21 chance in 1.7. Both of these numbers are far in excess of the number of possible cave systems, which is only 2^48 or 281 trillion or 2.81 x 10^14 because Java's Random only has 48 bits of internal state, which also means that only about 20 fully generated worlds (about 14 trillion chunks each) are required to use up every possible seed (every chunk has a unique seed based on the world seed and coordinates). Even a 64 bit RNG only has 1.8 x 10^19 states, 128 bit has 3.4 x 10^38, and there are 2.6 x 10^32 chunks in every possible Minecraft world, so it is virtually certain that the largest possible cave systems in both 1.6.4 and 1.7 do not exist, with 1.6.4 being unlikely even if every single chunk in every world had a unique seed (in reality, many chunks in the same world have the same seed due to a poor implementation, as seen in this map showing only cave systems and ravines in chunks with matching seeds, which occur at sign-reversed coordinate pairs. Any two worlds are also very likely to have some overlap; in fact, for any given seed there are 65535 other seeds with the exact same caves and many other features for the same reason there are only 2^48 unique chunk seeds; the biome generator is the only code that uses a custom 64 bit RNG).

This also does not take into account the sizes of individual caves, which can vary in width from 3 to 27 blocks (averaging 6; this is the maximum width and widening out from a minimum of 3) and in length from 85 to 194 blocks (including branches; branches are always 4-5 blocks in maximum width). The chance of a cave with the maximum width (26.5-27) is in itself an extraordinarily rare occurrence, with around one in 12 million chunks in 1.6.4 and one in 16 million chunks in 1.7+ (solely due to a lower amount of caves overall; no other changes were made other than to the size and frequency of cave systems) - and even then you may not find it if it goes under lava or above the surface/seafloor (on average 83% of caves are below sea level and 25% are below lava level, at least their starting points).

Also, while the chance of the largest possible cave system in 1.6.4 is far lower than in 1.7 and 1.7 has a higher chance of a cave system in a given chunk cave systems with 5 or more caves are more common in 1.6.4, with larger cave systems exponentially more common, as shown in these results from 1 billion simulated cave systems (15 billion chunks in 1.6.4 and 7 billion in 1.7+); the maximum size found in 1.7+ was 40 while the maximum in 1.6.4 was 80, and a size of 40 or more was more than 3 million times more likely in 1.6.4 (the sample size is too small at this point to get accurate results but the progression up to 38 suggests this is a big underestimate); a size of 20 was 32 times more common and a size of 10 was 2.27 times more common:

Of course, multiple cave systems often generate close enough to overlap; for example, this massive cave system in the seed "-7501191248410737040" (+/- any multiple of 2^48) in 1.6.4 contains a total of 526 caves across 32 individual cave systems:

Size 7 cave system at -448, 112; total number of caves: 9
Size 1 cave system at -416, 112; total number of caves: 2
Size 21 cave system at -352, 112; total number of caves: 39
Size 2 cave system at -480, 128; total number of caves: 2
Size 21 cave system at -336, 144; total number of caves: 27
Size 24 cave system at -400, 160; total number of caves: 40
Size 13 cave system at -384, 160; total number of caves: 19
Size 6 cave system at -512, 176; total number of caves: 6
Size 2 cave system at -464, 176; total number of caves: 2
Size 3 cave system at -256, 176; total number of caves: 5
Size 2 cave system at -304, 192; total number of caves: 2
Size 29 cave system at -448, 208; total number of caves: 36
Size 12 cave system at -416, 208; total number of caves: 18
Size 21 cave system at -400, 208; total number of caves: 28
Size 3 cave system at -352, 208; total number of caves: 6
Size 7 cave system at -256, 208; total number of caves: 9
Size 13 cave system at -448, 224; total number of caves: 13
Size 20 cave system at -352, 224; total number of caves: 34
Size 6 cave system at -352, 240; total number of caves: 6
Size 3 cave system at -336, 240; total number of caves: 3
Size 21 cave system at -304, 240; total number of caves: 28
Size 1 cave system at -256, 240; total number of caves: 1
Size 3 cave system at -464, 256; total number of caves: 9
Size 23 cave system at -400, 256; total number of caves: 28
Size 26 cave system at -368, 256; total number of caves: 37
Size 21 cave system at -416, 272; total number of caves: 34
Size 1 cave system at -352, 272; total number of caves: 4
Size 1 cave system at -480, 288; total number of caves: 3
Size 27 cave system at -416, 288; total number of caves: 43
Size 2 cave system at -384, 288; total number of caves: 2
Size 3 cave system at -448, 320; total number of caves: 3
Size 19 cave system at -352, 320; total number of caves: 28

Number of cave systems: 32

Initial number of caves: 364
Total number of caves: 526
Additional circular room caves: 162
Number of small caves: 511; average width is 6.11
Number of large caves: 15; average width is 13.75
Number of circular rooms: 101; average width is 10.9
Additional caves per circular room: 1.6

For comparison, this is a large but much more scattered cave system I found in the seed "-8138713038637852061" in 1.7+, with only 146 caves across 26 cave systems within the same area; the average size of each cave system is only about a third of the one above:

Size 1 cave system at 2448, -1120; total number of caves: 4

Size 6 cave system at 2320, -1104; total number of caves: 6
Size 1 cave system at 2464, -1104; total number of caves: 1
Size 8 cave system at 2384, -1088; total number of caves: 13
Size 1 cave system at 2336, -1072; total number of caves: 1
Size 3 cave system at 2320, -1056; total number of caves: 4
Size 5 cave system at 2384, -1056; total number of caves: 11
Size 8 cave system at 2288, -1040; total number of caves: 8
Size 1 cave system at 2288, -1024; total number of caves: 4
Size 6 cave system at 2496, -1024; total number of caves: 11
Size 6 cave system at 2512, -1024; total number of caves: 9
Size 1 cave system at 2352, -1008; total number of caves: 4
Size 1 cave system at 2384, -1008; total number of caves: 3
Size 3 cave system at 2464, -1008; total number of caves: 3
Size 1 cave system at 2368, -992; total number of caves: 4
Size 5 cave system at 2432, -992; total number of caves: 14
Size 4 cave system at 2448, -992; total number of caves: 7
Size 3 cave system at 2480, -992; total number of caves: 5
Size 1 cave system at 2352, -976; total number of caves: 1
Size 3 cave system at 2400, -976; total number of caves: 6
Size 1 cave system at 2384, -960; total number of caves: 1
Size 4 cave system at 2480, -960; total number of caves: 4
Size 6 cave system at 2416, -944; total number of caves: 12
Size 3 cave system at 2368, -928; total number of caves: 6
Size 1 cave system at 2416, -928; total number of caves: 1
Size 3 cave system at 2416, -912; total number of caves: 3

Number of cave systems: 26
Initial number of caves: 86
Total number of caves: 146
Additional circular room caves: 60
Number of small caves: 141; average width is 6.06
Number of large caves: 5; average width is 12.78
Number of circular rooms: 31; average width is 10.58
Additional caves per circular room: 1.94

These are the largest single cave systems that can generate in 1.6.4 and earlier (at least back to InfDev) and 1.7 and later, as seen below sea level and layer 20, the latter layer chosen since it makes it easier to see variations in cave density. I modified the code to make cave systems always generate at the maximum size and 16 chunks apart for reasons that will be seen below:

Here is a look at one of the 1.6.4 cave systems in-game (I modified terrain to be like a Superflat world without any decoration):

The 1.6.4 cave systems contain 156 tunnels and 39 circular rooms while the 1.7 cave systems contain 56 tunnels and 14 circular rooms; in each case the number of tunnels is 4 times the number of circular rooms since when one is generated 0-3 additional tunnels are added to an otherwise single tunnel as seen in this simplified code example:

"maxSize" is 40 for 1.6.4 and 15 for 1.7, which give a maximum size of 39 and 14 respectively (nextInt() returns a value between 0 and n-1), and with each iteration of the main loop there is a 25% chance of adding a circular room, which in turn has an additional 25% chance of adding 3 additional tunnels for a maximum of 4 generated from the same spot (each iteration also sets the starting coordinates of each room/tunnel(s) to random values between 0-15 for x and z (relative to the center chunk) and 0-126 for the y-coordinate).

Since there is a 25% chance of a circular room per iteration and a 25% chance of 4 tunnels this means that there is a 25% * 25% = 6.25% chance per iteration of the maximum number of tunnels. For a cave system with a size of 1 this means there is a 1 in 16 chance of 4 tunnels, for a size of 2 a one in 256 chance of 8 tunnels (6.25% ^ 2), for a size of 3 a one in 4096 chance of 12 tunnels, and so on until you reach the maximum sizes of 39 or 14.

For a size 39 cave system to have 156 tunnels the chance is (25% * 25%) ^ 39 = 1.1 x 10^-47 or one in 9.13 x 10^46.

For a size 14 cave system to have 56 tunnels the chance is (25% * 25%) ^ 14 = 1.4 x 10^-17 or one in 9.13 x 10^16.

However, that is not all - the chance of the maximum size being chosen is (maxSize ^ 3) or one in 64000 for 1.6.4 and one in 3375 for 1.7, and the chance of a chunk having a cave system (including a size of 0) is one in 15 in 1.6.4 and one in 7 in 1.7 for a combined chance of one in 960000 for 1.6.4 and one in 23625 for 1.7.

When combined with the above this results in a one in 8.8 x 10^52 chance of the largest possible cave system in 1.6.4 and a one in 1.7 x 10^21 chance in 1.7. Both of these numbers are far in excess of the number of possible cave systems, which is only 2^48 or 281 trillion or 2.81 x 10^14 because Java's Random only has 48 bits of internal state, which also means that only about 20 fully generated worlds (about 14 trillion chunks each) are required to use up every possible seed (every chunk has a unique seed based on the world seed and coordinates). Even a 64 bit RNG only has 1.8 x 10^19 states, 128 bit has 3.4 x 10^38, and there are 2.6 x 10^32 chunks in every possible Minecraft world, so it is virtually certain that the largest possible cave systems in both 1.6.4 and 1.7 do not exist, with 1.6.4 being unlikely even if every single chunk in every world had a unique seed (in reality, many chunks in the same world have the same seed due to a poor implementation, as seen in this map showing only cave systems and ravines in chunks with matching seeds, which occur at sign-reversed coordinate pairs. Any two worlds are also very likely to have some overlap; in fact, for any given seed there are 65535 other seeds with the exact same caves and many other features for the same reason there are only 2^48 unique chunk seeds; the biome generator is the only code that uses a custom 64 bit RNG).

This also does not take into account the sizes of individual caves, which can vary in width from 3 to 27 blocks (averaging 6; this is the maximum width and widening out from a minimum of 3) and in length from 85 to 194 blocks (including branches; branches are always 4-5 blocks in maximum width). The chance of a cave with the maximum width (26.5-27) is in itself an extraordinarily rare occurrence, with around one in 12 million chunks in 1.6.4 and one in 16 million chunks in 1.7+ (solely due to a lower amount of caves overall; no other changes were made other than to the size and frequency of cave systems) - and even then you may not find it if it goes under lava or above the surface/seafloor (on average 83% of caves are below sea level and 25% are below lava level, at least their starting points).

Also, while the chance of the largest possible cave system in 1.6.4 is far lower than in 1.7 and 1.7 has a higher chance of a cave system in a given chunk cave systems with 5 or more caves are more common in 1.6.4, with larger cave systems exponentially more common, as shown in these results from 1 billion simulated cave systems (15 billion chunks in 1.6.4 and 7 billion in 1.7+); the maximum size found in 1.7+ was 40 while the maximum in 1.6.4 was 80, and a size of 40 or more was more than 3 million times more likely in 1.6.4 (the sample size is too small at this point to get accurate results but the progression up to 38 suggests this is a big underestimate); a size of 20 was 32 times more common and a size of 10 was 2.27 times more common:

Of course, multiple cave systems often generate close enough to overlap; for example, this massive cave system in the seed "-7501191248410737040" (+/- any multiple of 2^48) in 1.6.4 contains a total of 526 caves across 32 individual cave systems:

Size 7 cave system at -448, 112; total number of caves: 9

Size 1 cave system at -416, 112; total number of caves: 2

Size 21 cave system at -352, 112; total number of caves: 39

Size 2 cave system at -480, 128; total number of caves: 2

Size 21 cave system at -336, 144; total number of caves: 27

Size 24 cave system at -400, 160; total number of caves: 40

Size 13 cave system at -384, 160; total number of caves: 19

Size 6 cave system at -512, 176; total number of caves: 6

Size 2 cave system at -464, 176; total number of caves: 2

Size 3 cave system at -256, 176; total number of caves: 5

Size 2 cave system at -304, 192; total number of caves: 2

Size 29 cave system at -448, 208; total number of caves: 36

Size 12 cave system at -416, 208; total number of caves: 18

Size 21 cave system at -400, 208; total number of caves: 28

Size 3 cave system at -352, 208; total number of caves: 6

Size 7 cave system at -256, 208; total number of caves: 9

Size 13 cave system at -448, 224; total number of caves: 13

Size 20 cave system at -352, 224; total number of caves: 34

Size 6 cave system at -352, 240; total number of caves: 6

Size 3 cave system at -336, 240; total number of caves: 3

Size 21 cave system at -304, 240; total number of caves: 28

Size 1 cave system at -256, 240; total number of caves: 1

Size 3 cave system at -464, 256; total number of caves: 9

Size 23 cave system at -400, 256; total number of caves: 28

Size 26 cave system at -368, 256; total number of caves: 37

Size 21 cave system at -416, 272; total number of caves: 34

Size 1 cave system at -352, 272; total number of caves: 4

Size 1 cave system at -480, 288; total number of caves: 3

Size 27 cave system at -416, 288; total number of caves: 43

Size 2 cave system at -384, 288; total number of caves: 2

Size 3 cave system at -448, 320; total number of caves: 3

Size 19 cave system at -352, 320; total number of caves: 28

Number of cave systems: 32

Initial number of caves: 364

Total number of caves: 526

Additional circular room caves: 162

Number of small caves: 511; average width is 6.11

Number of large caves: 15; average width is 13.75

Number of circular rooms: 101; average width is 10.9

Additional caves per circular room: 1.6

For comparison, this is a large but much more scattered cave system I found in the seed "-8138713038637852061" in 1.7+, with only 146 caves across 26 cave systems within the same area; the average size of each cave system is only about a third of the one above:

Size 1 cave system at 2448, -1120; total number of caves: 4

Size 6 cave system at 2320, -1104; total number of caves: 6

Size 1 cave system at 2464, -1104; total number of caves: 1

Size 8 cave system at 2384, -1088; total number of caves: 13

Size 1 cave system at 2336, -1072; total number of caves: 1

Size 3 cave system at 2320, -1056; total number of caves: 4

Size 5 cave system at 2384, -1056; total number of caves: 11

Size 8 cave system at 2288, -1040; total number of caves: 8

Size 1 cave system at 2288, -1024; total number of caves: 4

Size 6 cave system at 2496, -1024; total number of caves: 11

Size 6 cave system at 2512, -1024; total number of caves: 9

Size 1 cave system at 2352, -1008; total number of caves: 4

Size 1 cave system at 2384, -1008; total number of caves: 3

Size 3 cave system at 2464, -1008; total number of caves: 3

Size 1 cave system at 2368, -992; total number of caves: 4

Size 5 cave system at 2432, -992; total number of caves: 14

Size 4 cave system at 2448, -992; total number of caves: 7

Size 3 cave system at 2480, -992; total number of caves: 5

Size 1 cave system at 2352, -976; total number of caves: 1

Size 3 cave system at 2400, -976; total number of caves: 6

Size 1 cave system at 2384, -960; total number of caves: 1

Size 4 cave system at 2480, -960; total number of caves: 4

Size 6 cave system at 2416, -944; total number of caves: 12

Size 3 cave system at 2368, -928; total number of caves: 6

Size 1 cave system at 2416, -928; total number of caves: 1

Size 3 cave system at 2416, -912; total number of caves: 3

Number of cave systems: 26

Initial number of caves: 86

Total number of caves: 146

Additional circular room caves: 60

Number of small caves: 141; average width is 6.06

Number of large caves: 5; average width is 12.78

Number of circular rooms: 31; average width is 10.58

Additional caves per circular room: 1.94

TheMasterCaver's First World - possibly the most caved-out world in Minecraft history - includes world download.

TheMasterCaver's World - my flagship mod which combines my own ideas with 1.7+ features, with emphasis on underground content.

Why do I still play in 1.6.4?