Phrases involving the word 'head' with words such as 'out of', 'off' etc usually suggest that the person concerned is driven to mental distraction or even almost 'madness', as it were.
For example, if you are 'bored out of your skull', that means you are so mentally drained by the tedium that you are virtually demented. So, to 'laugh your head off' is to be so amused that you have effectively lost control of yourself...laughing uproariously or uncontrollably.
If by 'originate' you mean "Who first said/wrote it?" I do not know the answer to that. What I have described is the sort of situation which became the source of the saying.