The idea of not being able to move as an intruder or monster comes your way is classic nightmare material, but for some people, this is their reality. Around 7.6 percent of the world's population has had at least one attack of sleep paralysis, but for some people, the odds are even higher - a 2011 study found that 28.3 percent of students, and 31.9 percent of psychiatric patients experience at least one episode of sleep paralysis in their lives.
So what exactly is sleep paralysis? The disorder comes in many forms, but generally, those affected cannot move or speak for up to 2 minutes after they wake, or just after falling asleep. Some people also experience the sense of a physical weight being pushed onto their chest, the inability to breathe, unnatural involuntary movements, an evil presence in the room, and visual, auditory, or physical hallucinations.
Sleep paralysis is related to your rapid-eye-movement (REM) sleep and the body going into a state of atonia. Atonia paralyses the muscles of the body while sleeping - probably to stop the dreamer from lashing out, or acting out their dream in bed. The feeling of paralysis occurs when you wake before REM is finished, or fall asleep and go straight into REM. This means that your body stays paralysed, but your mind is awake.
Obviously this is exceptionally scary for those who experience it, but for some people, things can get even worse.
The hallucinations caused by sleep paralysis are not well understood, but could be due to a hyper-vigilant state or emergency response activated in the midbrain when a person feels vulnerable to an attack. This heightens the activity of the nerves, so the paralysis - and therefore helplessness - appears to cause increasingly vivid effects.
Sleep paralysis is not a new phenomenon - there's been documented evidence of it occurring since at least the early 19th century. During this period it was thought to be the work of demons sitting on the chests of victims, witchcraft, or magical or spiritual possessions. Later on, the cause was attributed to a person's diet, with bad wine and greasy meats being singled out as the main culprits.
Although today's scientists haven't got all the answers, we do know that it isn't due to demons, spiritual possessions, or cheap wine. It's often brought on by interruptions in regular sleeping patterns, and there does appear to be some kind of genetic component. Researchers at the Howard Hughes Medical Institute in Philadelphia reported in 2012 that if one twin experiences sleep paralysis, the other is more likely to also experience it. They concluded that it's due to an interaction of environmental factors and a person's genetic background.
"Features of dissociated REM sleep, such as sleep paralysis and hypnagogic hallucinations are highly heritable and frequent in the general population, particularly with insufficient sleep," they wrote in the journal Cell.
Although many of us are likely to experience sleep paralysis in our lifetime, at this stage, there's no cure or treatment available, and scientists are still working on understanding the condition. But it is important to remember that although these episodes can be terrifying, they will pass, you're not in any actual danger, and the episode itself will usually only last a few seconds.