Pain in side

Hi everyone! I got a pain in my side last week and I’ve had it before but it hasn’t gone away this time. I was wondering if anyone knows what this pain means and when should I call my doctor about it? Thanks in advance!

At least, which side? upper or lower? And what was this pain last time?

My right side under my rib cage. It hurts to touch and when I lay on my right side.

I'd get to the doc if possible, ER if not.