Hanging is the lethal suspension of a person by a ligature. The Oxford English Dictionary
Oxford English Dictionary
The Oxford English Dictionary , published by the Oxford University Press, is the self-styled premier dictionary of the English language. Two fully bound print editions of the OED have been published under its current name, in 1928 and 1989. The first edition was published in twelve volumes , and...

states that hanging in this sense is "specifically to put to death by suspension by the neck", though it formerly also referred to crucifixion
Crucifixion is an ancient method of painful execution in which the condemned person is tied or nailed to a large wooden cross and left to hang until dead...

 and death by impalement
Impalement is the traumatic penetration of an organism by an elongated foreign object such as a stake, pole, or spear, and this usually implies complete perforation of the central mass of the impaled body...

 in which the body would remain "hanging".

Hanging oneself is also used to describe a method of suicide
Suicide is the act of intentionally causing one's own death. Suicide is often committed out of despair or attributed to some underlying mental disorder, such as depression, bipolar disorder, schizophrenia, alcoholism, or drug abuse...

 in which a person applies a ligature to the neck and brings about unconsciousness and then death, by means of partial suspension or partial weight-bearing on the ligature.