Minecraft wiki entry for Dungeon, associated text: In Java Edition, dungeons generate naturally in the Overworld at any altitude (provided it is next to a cave) regardless of whether "Generate structures" world creation option has been toggled off for said world.[1] For each chunk, 8 attempts are made to generate a dungeon; it is possible, though unlikely, for multiple attempts to succeed. In Bedrock Edition, dungeons can generate as underground structures above sea level.