It's often used as a way of avoiding saying 'hell' around the especially sensitive.
It is a mild swear word or expletive.
It's used to mildly express surprise or frustration to something. Eg "The car won't start" … "Oh heck!" similar to "Oh my God".