Constipation

I am having the worst constipation. It has been a day since I have gone and I have tried everything. I am a healthy person and my diet consists of fruit and whole grains. I'm having the worst pain. Did you guys try anything that worked and was safe during pregnancy?