A semiconductor device, comprising: a semiconductor substrate including a bulk donor; an active portion provided in the semiconductor substrate; and an edge termination structure portion provided between the active portion and an end side of the semiconductor substrate in the semiconductor substrate at an upper surface of the semiconductor substrate, a well region of a p type provided between the active portion and the edge termination structure portion at the upper surface of the semiconductor substrate, wherein the semiconductor substrate comprises a low-concentration region in the active portion and below the well region and having a bulk donor concentration, a first high-concentration region in the active portion and below said low-concentration region in a depth direction, wherein the first high-concentration region includes hydrogen and has a higher donor concentration than the bulk donor concentration, wherein donors of the first high-concentration region include impurities and hydrogen donors, and a buffer region of an n type provided below the first high-concentration region; the edge termination structure portion comprises a second high-concentration region above the buffer region, wherein the second high-concentration region includes hydrogen, and has a higher donor concentration than the bulk donor concentration, wherein donors of the second high-concentration region include impurities and hydrogen donors, wherein a distance between the upper surface of the buffer region and the upper surface of the second high-concentration region in the depth direction is longer than a distance between the upper surface of the buffer region and the upper surface of the first high-concentration region; a hydrogen concentration distribution in the depth direction in the first high-concentration region has a first hydrogen concentration peak in the first high-concentration region proximate to the low-concentration region in the depth direction; the active portion and the well region have a plurality of gate trench portions provided on the upper surface of the semiconductor substrate in a predetermined interval along an array direction parallel to the upper surface; among a plurality of the gate trench portions, a distance in the array direction between the gate trench portion closest to the edge termination structure portion and the second high-concentration region is three times or more of the standard deviation of the first hydrogen concentration peak in a hydrogen chemical concentration distribution in the depth direction; the well region is provided from the upper surface of the semiconductor substrate to a depth deeper than a lower end of the gate trench portion; and a boundary (Xb) between the first high-concentration region and the second high-concentration region in the array direction is overlapped with the well region. a semiconductor substrate including a bulk donor; an active portion provided in the semiconductor substrate; and an edge termination structure portion provided between the active portion and an end side of the semiconductor substrate in the semiconductor substrate at an upper surface of the semiconductor substrate, a well region of a p type provided between the active portion and the edge termination structure portion at the upper surface of the semiconductor substrate, wherein the semiconductor substrate comprises a low-concentration region in the active portion and below the well region and having a bulk donor concentration, a first high-concentration region in the active portion and below said low-concentration region in a depth direction, wherein the first high-concentration region includes hydrogen and has a higher donor concentration than the bulk donor concentration, wherein donors of the first high-concentration region include impurities and hydrogen donors, and a buffer region of an n type provided below the first high-concentration region; the edge termination structure portion comprises a second high-concentration region above the buffer region, wherein the second high-concentration region includes hydrogen, and has a higher donor concentration than the bulk donor concentration, wherein donors of the second high-concentration region include impurities and hydrogen donors, wherein a distance between the upper surface of the buffer region and the upper surface of the second high-concentration region in the depth direction is longer than a distance between the upper surface of the buffer region and the upper surface of the first high-concentration region; a hydrogen concentration distribution in the depth direction in the first high-concentration region has a first hydrogen concentration peak in the first high-concentration region proximate to the low-concentration region in the depth direction; the active portion and the well region have a plurality of gate trench portions provided on the upper surface of the semiconductor substrate in a predetermined interval along an array direction parallel to the upper surface; among a plurality of the gate trench portions, a distance in the array direction between the gate trench portion closest to the edge termination structure portion and the second high-concentration region is three times or more of the standard deviation of the first hydrogen concentration peak in a hydrogen chemical concentration distribution in the depth direction; the well region is provided from the upper surface of the semiconductor substrate to a depth deeper than a lower end of the gate trench portion; and a boundary (Xb) between the first high-concentration region and the second high-concentration region in the array direction is overlapped with the well region.