Spoke my mind

I have a problem that things I say inadvertently upset some people and I don't know how to convey that what I say isn't I tended to upset or be rude how can I explain this to Atypical person in words that they would understand. I'm feeling really bad that iv made someone sad because of something I have said,how can make things right. Thanks John