Leg pain 30 weeks

I have been having leg pain while sleeping for a while now. I’m 30 weeks 3 days. tHey only hurt me when I’m sleeping in bed. I can lay in bed and watch tv and feel fine. The pain is only when I lay in bed and sleep. When I get up and walk around I’m completely fine. Is this normal?