Should I go to the er?

I’ve been straining to poop and I bled a little bit this morning from it. I then just went to the bathroom and this came out of my butt, a clot of blood. Should I go to the er and just the doctor? Anyone else had this happen?