How are you doing for salt, magnesium, and potassium? If you are getting enough salt, it is easier for your body to regulate the other two, but you may also need to supplement them. Plenty of information on this site about how to do that, just search on “cramps” and it should all show up.
Commercial supplements often contain minerals in forms that are cheap to produce, but that are less bio-available, so I agree with the idea that our diet should supply all we need. But on the other hand, some of us have been damaged and may need a bit of help.
Remember, too, that the kidneys excrete sodium more readily once insulin drops, so we do need to work a bit harder on keto to be sure we get enough salt. Over- or under-hydrating does not help, so drinking to thirst is key, there. Magnesium and potassium are both found in meat (especially in marrow), so a cup or two of bone broth a day can be a good idea. Especially if it’s homemade and simmered long enough for the minerals to leach out of the bones.