Empathy is a powerful tool in dealing with difficult people. It's hard though to try and put yourself in someone else's shoes, especially if they are being difficult towards you or you have known them to be challenging from previous interactions. It might also feel like being empathetic and trying to understand such a person is taking on an unnecessary additional burden that you really don't need. In some cases, it is, but doing so mostly leads to having a smoother interaction and also usually changes the way they interact with you in the future.
Being empathetic involves trying to understand their feelings and motivations. Most of the time, difficult behavior stems from stress, insecurity or unmet needs. Acknowledging their emotions, helps us respond with compassion rather than judgment.
For example, if a colleague is being particularly abrasive, consider what might be causing their stress. Are they under a lot of pressure from a deadline? Do they feel undervalued or unsupported? Addressing the root cause of their behavior can help diffuse tension and open the door to more constructive communication.
Empathy doesn't mean excusing bad behavior though, but it does mean approaching the situation with a mindset of understanding. This can help you remain calm and composed, making it easier to find common ground and work towards a resolution.