It's just a weird phenomenon in which your phrenic nerve (which controls the diaphragm) starts firing irregularly. As to cause, it seems to vary far and wide, and you'll find claims blaming anything from drinking soda to laughing too hard, which makes me think research on the subject is a bit scarce. A cursory search of "hiccup" in Pubmed finds papers investigating hiccups in various conditions such as esophageal disease, but nothing immediately jumps out at me as conclusive in terms of typical cause.
From what I recall of dissecting this particular nerve, it passes through a large number of anatomical structures, starting with your neck musculature and passing down between your heart/lung before finally reaching your diaphragm, so there are plenty of opportunities to disrupt the nerves' (you have one on each side of your body) firing pattern, especially given everyone's slight physical differences. Unless a patient has intractable/recurrent hiccups, I suspect the common case is idiopathic, particularly since your nervous system usually corrects it on its own after a while.
More questions on Quora: