{
  "id": "nether-portal",
  "version": "75e55aecdd5a",
  "status": "published",
  "name": "Nether Portal Calculator",
  "question": "Where do I build my Nether portal?",
  "summary": "Converts Minecraft coordinates between the Overworld and the Nether: X and Z divide by 8 going to the Nether and multiply by 8 coming back, and Y stays the same.",
  "category": "game",
  "subcategory": "video-games",
  "url": "https://www.acalculator.org/game/nether-portal-calculator",
  "markdown": "https://www.acalculator.org/game/nether-portal-calculator.md",
  "kind": "function",
  "method": "Overworld to Nether: X ÷ 8 and Z ÷ 8; Nether to Overworld: X × 8 and Z × 8; Y is unchanged; block coordinates round down.",
  "assumptions": [
    "Horizontal distances in the Nether are 1/8 of the Overworld’s (Java and Bedrock editions).",
    "Block coordinates are rounded down (floor), as the game does, so −37.5 becomes −38.",
    "The game links a portal to the nearest existing portal within a search range, so two portals close together may link to the same one."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "from": {
        "title": "Convert",
        "description": "Whether you start from Overworld coordinates or from Nether coordinates.",
        "type": "string",
        "enum": [
          "overworld",
          "nether"
        ]
      },
      "x": {
        "title": "X coordinate",
        "description": "The X coordinate (east–west for X, north–south for Z) in the dimension you start from.",
        "type": "number",
        "minimum": -30000000,
        "maximum": 30000000
      },
      "y": {
        "title": "Y coordinate",
        "description": "The height. It is the same in both dimensions.",
        "type": "number",
        "minimum": -64,
        "maximum": 320
      },
      "z": {
        "title": "Z coordinate",
        "description": "The Z coordinate (east–west for X, north–south for Z) in the dimension you start from.",
        "type": "number",
        "minimum": -30000000,
        "maximum": 30000000
      }
    }
  },
  "outputs": {
    "coordinates": {
      "label": "Build the portal at",
      "description": "The block coordinates X, Y, Z in the other dimension: X and Z rounded down.",
      "format": "text"
    },
    "blockX": {
      "label": "Block X",
      "description": "The X coordinate in the other dimension, rounded down to a whole block.",
      "format": "integer"
    },
    "blockZ": {
      "label": "Block Z",
      "description": "The Z coordinate in the other dimension, rounded down to a whole block.",
      "format": "integer"
    },
    "exactX": {
      "label": "Exact X",
      "description": "X ÷ 8 going to the Nether, X × 8 going to the Overworld, before rounding.",
      "format": "number"
    },
    "exactZ": {
      "label": "Exact Z",
      "description": "Z ÷ 8 going to the Nether, Z × 8 going to the Overworld, before rounding.",
      "format": "number"
    },
    "note": {
      "label": "Note",
      "description": "Shown when the target is outside the world border or in the Nether’s bedrock roof or floor.",
      "format": "text"
    },
    "blockY": {
      "label": "Y",
      "description": "The height, unchanged.",
      "format": "number"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "from": "overworld",
      "x": 1000,
      "y": 64,
      "z": -300
    },
    "outputs": {
      "coordinates": "X 125, Y 64, Z -38",
      "blockX": 125,
      "blockZ": -38,
      "exactX": 125,
      "exactZ": -37.5,
      "blockY": 64
    },
    "text": "Converting Overworld to Nether from X 1,000, Z -300: build the portal at X 125, Y 64, Z -38."
  },
  "examples": [
    {
      "given": {
        "from": "overworld",
        "x": 1000,
        "y": 64,
        "z": -300
      },
      "expect": {
        "exactX": 125,
        "exactZ": -37.5,
        "blockX": 125,
        "blockZ": -38,
        "coordinates": "X 125, Y 64, Z -38"
      },
      "source": "hand calculation in content.mdx: 1000 ÷ 8 = 125; −300 ÷ 8 = −37.5, rounded down to −38"
    },
    {
      "given": {
        "from": "nether",
        "x": 100,
        "y": 70,
        "z": -20
      },
      "expect": {
        "exactX": 800,
        "exactZ": -160,
        "coordinates": "X 800, Y 70, Z -160"
      },
      "source": "hand calculation in content.mdx: 100 × 8 = 800; −20 × 8 = −160"
    },
    {
      "given": {
        "from": "overworld",
        "x": 15,
        "z": 7
      },
      "expect": {
        "exactX": 1.875,
        "blockX": 1,
        "blockZ": 0,
        "coordinates": "X 1, Z 0"
      },
      "source": "hand calculation in content.mdx: 15 ÷ 8 = 1.875 → 1; 7 ÷ 8 = 0.875 → 0"
    }
  ],
  "sources": [
    "Minecraft Wiki, World border (29,999,984 blocks from the origin by default): https://minecraft.wiki/w/World_border",
    "Minecraft Wiki, The Nether (bedrock floor Y 0 to 4, roof Y 123 to 127, Java Edition): https://minecraft.wiki/w/The_Nether",
    "Minecraft Wiki, Nether portal (coordinate scale, rounding, search range): https://minecraft.wiki/w/Nether_portal"
  ],
  "related": [
    "vorici",
    "point-buy"
  ],
  "changelog": [
    {
      "date": "2026-09-28",
      "note": "Thousands commas in the headline; notes for the world border and the Nether bedrock; the sentence names the direction (WP-70 QA)."
    }
  ]
}
