No expert, but I can relate my experience.
With RA, when you spend time in any one position, you stiffen up, then try rolling over and everything hurts all over again. That's why it takes so long to get moving in the mornings.
Having a lot of sleepless nights myself from this. Are you in a flare? I'm told it is worse when in flare.