Template:Hp
From D&D Wiki
Usage
This template calculates the average HP of a 5e creature based on its size, number of hit dice, and Constitution modifier. To use it, simply type in the following example.
{{hp|count|size|conmod}}
Replace "count" with how many HD the creature possesses. Replace "size" with the size of the hit die, such as 6, 8 or 10. Finally, replace "conmod" with the creature's Constitution modifier. As an example, a typical minotaur has 9d10 HD with a Constitution modifier of +3. Below, you'll see how the template would look when filled out for a minotaur.
{{hp|9|10|3}}
Entering the above template on a page would return the value of "76", which would be the minotaur's average hit points.