What could be the cause of sporadic sharp pain in uterus at 28 weeks?

Pain. The uterus is a muscle and it contracts at times and I bet this is the cause of your sporadic pain. I hope this helps!