There are a number of strategies to counter rude comments, such as responding in ways to trivialize the person making the rude comment or making it sound like the comment is not bothersome. Various forms of sarcasm can counter rude comments.
One way to counter someone unintentionally making a rude comment is to make the person realize it is offensive, such as "Did you mean to be so rude?" Some comebacks are sarcastic such as "Have a nice day, somewhere else," or "You would argue with a fence post." Another classic and frequently used comeback is some variation of "Your mom."
For individuals intentionally trying to hurt someone emotionally, comebacks to trivialize an insulter such as "You know what that sounds like? Not my problem!" or "Did I ask for your opinion?" or "Sorry, did you say something?" help to convince the insulter that rude words are powerless.