This all depends upon what exactly is happening to you. It could be a form of sleep paralysis. If that's the case, don't fight it. Struggling against it is what anchors you in it. I hate to say it, but if you can't move, give up. That is, don't try to move. Instead, just relax some more. Close your eyes, clear your mind, do not struggle. Often, just surrendering to the paralysis will instantly break it. Of course, this would mean you would probably wake up. If it is sleep paralysis, I suggest you try to dive inward rather than get up from the bed. Close your eyes and go into your mind rather than trying to get up and explore your room.

Otherwise, if this is indeed a dream which merely takes place in your bed, then you may simply be limited by your own expectations. What we prepare for and what we expect are fed into our experience of the moment we're in. If you feel as if you can't move, and you're lying there in bed with a lifetime of experience which tells your mind that you cannot indeed float out of bed... then you're probably not going to get that far. You've got to fix that, luckily, it's easy.

Your position in a dream is the location of your perception. That sounds odd at first, but when you consider that you practically ARE your mind's eye while you're dreaming, then it starts to make more sense. While you still have the sensation of the bed beneath you, you are anchored to your bed. You want to try to stir up sensations which are stronger than the sensation of lying in bed. If you simply recall what it feels like at the peak of a jump, that moment of weightlessness, then that can go a long ways. If you've ever flown in a dream before, try to recall what it felt like to propel yourself through space. Some people imagine sinking into the bed, which works really well because it doesn't rely on the denial of the sensation of contact with the bed. I sometimes find that working up a sort of oscillation feeling helps. That is, I will "visualize" movement in one direction, then the other, and back. I repeat this until I'm practically vibrating or spinning. The sensation eventually becomes so strong that it overcomes the sensation of lying in bed and then it's almost as if the cord holding me in my body snaps and I go flying. Sometimes, however, it's too strong and it wakes me up. It's all about finding what works for you.

Your vision might also be anchoring you in place. So closing your eyes and focusing on visualizing where/when You want to be while you activate the sensation of movement could trick your brain into thinking that you're moving to that location. Once there, you might not be still lying in bed, and therefore wouldn't have to worry about being stuck.