Thanks for the query.
The possible causes are:
Round ligament pain: with the increasing size of the uterus
the round ligaments will stretch.
When you move in sleep, sudden change in position occur leading stretching of ligament which further leads to pain.
Braxton Hicks contractions
are irregular, infrequent contractions which lead to tightening of uterus but these are painless usually.
Usually these will subside soon, if they persist or become severe better to get examine once.