{
  "id": "dnd-hp",
  "version": "bb8dc22bfb6f",
  "status": "published",
  "name": "DnD HP Calculator",
  "question": "5e HP calculator by class and level",
  "summary": "Works out a 5e character’s hit point maximum from the class, level and Constitution score, with the fixed-value total, the lowest, highest and average totals when rolling, and the hit dice.",
  "category": "game",
  "subcategory": "tabletop",
  "url": "https://www.acalculator.org/game/dnd-hp-calculator",
  "markdown": "https://www.acalculator.org/game/dnd-hp-calculator.md",
  "kind": "function",
  "method": "HP = max(1, die + CON mod) + extra at 1st level, plus max(1, fixed value + CON mod) + extra for each later level; fixed value = die ÷ 2 + 1; CON mod = ⌊(score − 10) ÷ 2⌋.",
  "assumptions": [
    "One class from 1st level (no multiclassing). Hit dice: barbarian d12; fighter, paladin and ranger d10; bard, cleric, druid, monk, rogue and warlock d8; sorcerer and wizard d6.",
    "Each level adds at least 1 hit point before the per-level bonus, even with a very low Constitution. The SRD sets no floor; this page uses one so a level never lowers the maximum.",
    "The Constitution modifier counts at every level, as if the current score had applied from 1st level."
  ],
  "inputs": {
    "$schema": "https://json-schema.org/draft/2020-12/schema",
    "type": "object",
    "properties": {
      "class": {
        "title": "Class",
        "description": "The character’s class, which sets the hit die (d6 to d12).",
        "type": "string",
        "enum": [
          "barbarian",
          "bard",
          "cleric",
          "druid",
          "fighter",
          "monk",
          "paladin",
          "ranger",
          "rogue",
          "sorcerer",
          "warlock",
          "wizard"
        ]
      },
      "level": {
        "title": "Level",
        "description": "The character level, from 1 to 20.",
        "type": "integer",
        "minimum": 1,
        "maximum": 20
      },
      "con": {
        "title": "Constitution score",
        "description": "The Constitution ability score, from 1 to 30; the modifier comes from it.",
        "type": "integer",
        "minimum": 1,
        "maximum": 30
      },
      "extra": {
        "title": "Extra hit points per level",
        "description": "A bonus added every level: 1 for a hill dwarf or a draconic bloodline sorcerer, 0 for none.",
        "type": "integer",
        "minimum": 0,
        "maximum": 10
      }
    }
  },
  "outputs": {
    "fixed": {
      "label": "Hit point maximum (fixed value)",
      "description": "The maximum at 1st level, then the class’s fixed value each later level, all with the Constitution modifier.",
      "format": "integer"
    },
    "average": {
      "label": "Average when rolling",
      "description": "The expected maximum if each later level is a roll of the hit die.",
      "format": "number"
    },
    "lowest": {
      "label": "Lowest when rolling",
      "description": "The maximum if every later roll is a 1.",
      "format": "integer"
    },
    "highest": {
      "label": "Highest when rolling",
      "description": "The maximum if every later roll is the top of the die.",
      "format": "integer"
    },
    "modifier": {
      "label": "Constitution modifier",
      "description": "(score − 10) ÷ 2, rounded down.",
      "format": "text"
    },
    "hitDice": {
      "label": "Hit dice",
      "description": "One hit die per level, such as 5d10.",
      "format": "text"
    },
    "perLevel": {
      "label": "Hit points per later level",
      "description": "The fixed value + the Constitution modifier + the extra, at least 1 before the extra.",
      "format": "integer"
    }
  },
  "defaultAnswer": {
    "inputs": {
      "class": "fighter",
      "level": 5,
      "con": 14,
      "extra": 0
    },
    "outputs": {
      "fixed": 44,
      "average": 42,
      "lowest": 24,
      "highest": 60,
      "modifier": "+2",
      "hitDice": "5d10",
      "perLevel": 8
    },
    "text": "A level 5 character with 5d10 hit dice and a +2 Constitution modifier has 44 hit points."
  },
  "examples": [
    {
      "given": {
        "class": "fighter",
        "level": 5,
        "con": 14,
        "extra": 0
      },
      "expect": {
        "fixed": 44,
        "lowest": 24,
        "highest": 60,
        "average": 42,
        "modifier": "+2",
        "hitDice": "5d10"
      },
      "source": "hand calculation in content.mdx: 10 + 2 = 12 at 1st level, then 4 × (6 + 2) = 32, total 44; Wizards of the Coast, System Reference Document 5.1 (CC BY 4.0), Classes, Hit Points (1st level: the hit die’s maximum + Constitution modifier; later levels: 1 roll of the hit die, or the fixed value, + Constitution modifier) and Ability Scores and Modifiers. https://media.wizards.com/2023/downloads/dnd/SRD_CC_v5.1.pdf"
    },
    {
      "given": {
        "class": "barbarian",
        "level": 1,
        "con": 16,
        "extra": 0
      },
      "expect": {
        "fixed": 15,
        "lowest": 15,
        "highest": 15,
        "hitDice": "1d12"
      },
      "source": "5th Edition SRD (an HTML copy of SRD 5.1), Barbarian: Hit Points at 1st Level 12 + your Constitution modifier; at higher levels 1d12 (or 7) + your Constitution modifier. https://5thsrd.org/character/classes/barbarian/; hand calculation in content.mdx: 12 + 3 = 15"
    },
    {
      "given": {
        "class": "wizard",
        "level": 3,
        "con": 8,
        "extra": 1
      },
      "expect": {
        "fixed": 14,
        "perLevel": 4,
        "modifier": "−1"
      },
      "source": "hand calculation in content.mdx: (6 − 1) + 1 = 6 at 1st level, then 2 × ((4 − 1) + 1) = 8, total 14; Wizards of the Coast, System Reference Document 5.1 (CC BY 4.0), Classes, Hit Points (1st level: the hit die’s maximum + Constitution modifier; later levels: 1 roll of the hit die, or the fixed value, + Constitution modifier) and Ability Scores and Modifiers. https://media.wizards.com/2023/downloads/dnd/SRD_CC_v5.1.pdf"
    },
    {
      "given": {
        "class": "sorcerer",
        "level": 2,
        "con": 1,
        "extra": 0
      },
      "expect": {
        "fixed": 2,
        "lowest": 2,
        "highest": 2,
        "modifier": "−5"
      },
      "source": "hand calculation in content.mdx: max(1, 6 − 5) = 1, then max(1, 4 − 5) = 1, total 2; Wizards of the Coast, System Reference Document 5.1 (CC BY 4.0), Classes, Hit Points (1st level: the hit die’s maximum + Constitution modifier; later levels: 1 roll of the hit die, or the fixed value, + Constitution modifier) and Ability Scores and Modifiers. https://media.wizards.com/2023/downloads/dnd/SRD_CC_v5.1.pdf"
    }
  ],
  "sources": [
    "Wizards of the Coast, System Reference Document 5.1 (CC BY 4.0), Classes (Hit Points at 1st Level and at Higher Levels for each class), Ability Scores and Modifiers, Dwarf (Dwarven Toughness) and Sorcerer (Draconic Resilience). https://media.wizards.com/2023/downloads/dnd/SRD_CC_v5.1.pdf (retrieved 2026-10-02)",
    "5th Edition SRD, an HTML copy of SRD 5.1: Barbarian (Hit Points at 1st Level: 12 + your Constitution modifier; at Higher Levels: 1d12 (or 7) + your Constitution modifier per barbarian level after 1st). https://5thsrd.org/character/classes/barbarian/ (retrieved 2026-10-02)"
  ],
  "related": [
    "point-buy",
    "dice-probability"
  ],
  "changelog": []
}
