Question: is gosh a real word?
Answer: Gosh has no literal meaning. It's not supposed to. It's a Euphemism, which means it's a word that is used instead of a taboo word (in this case, as you suggest, the taboo word is God).