tightening on my stomach

I'm 36 + 6 weeks today this morning when I was in bed my stomach was tightening.. I thought it was just the baby moving however it was coming and going for about 10 times, it was sore however it was becoming really uncomfy!
Can anyone explain what this could be