M.D.
I had a similar type of pain on and off for over 10 years and it turned out to be my gallbladder. Apparently it was tricky to diagnose since I was in my 20s, not overweight and the pain was on my left side. I was told it was a pulled muscle or a nervous stomach over and over. I finally had an ultrasound of the gallbladder (I'd had all kinds of other tests and thought they'd already checked it) and they found stones. I had it removed and haven't had any pain since then. Definitely have them check it. If it's your gallbladder, the removal is a pretty simple operation (usually you don't have to stay overnight at the hospital) and it doesn't take long to feel much better!