Hiccups occur when your diaphragm contracts in a spastic, involuntary manner. You can get rid of hiccups by stopping the spasms.