Food sensitivities, as well as small intestinal bacterial overgrowth (SIBO), are often the cause of stomach cramps. When you have SIBO and eat FODMAP- rich foods the bad bacteria in your intestine overproduce gas leading to cramps. You may want to try an elimination diet or at least start with low FODMAP diet and see if your symptoms of gas, bloating and cramps improve.