Leg cramps while pregnant

Ileia

I know it's more common while pregnant but I get that really tight leg cramps when I stretch right when I wake up and now my legs are still sore from it any ideas on what to do to prevent it