As a consultant, you’re often looked upon as an outsider, an unwelcome intrusion to the departmental clique at the client company. Perhaps you were brought in by upper management and touted as the savior of a project that is falling behind on critical due dates — sparking anger and resentment among the in-house team that may have fathered the project. It’s an occupational hazard — IT consultants often find themselves mired in ugly office politics.

There are a variety of reasons why people love to hate consultants. Many people — especially those in leadership roles — do not look favorably upon others who exhibit more initiative and drive than they do. And in my experience, even a little initiative puts you ahead of 90 percent of the current workforce.

Often, your client’s staff is actually predisposed to finding fault with you, and personality conflicts will arise from those feelings. Some people will take an instant dislike to you, and to make matters worse, some of these people may be in a position to dislodge you from your job.

So how can you turn a no-win situation into a productive one for both you and the company? In this article, I’ll describe a few techniques you can use to protect yourself when you find you’re labeled as “the enemy” at the client site.

Tip #1: Document your work with e-mail

All correspondences should include e-mail to avoid any “he-said, she-said” arguments. Whether you have a telephone conversation, a quick hallway chat, or a meeting — all of those discussions should be followed up with an e-mail that summarizes what was discussed. For particularly heated issues, I recommend avoiding telephone conversations because e-mail provides better documentation of exactly how the other person interacted with you.

Make sure that you Cc those who may be an ally in the chain of command on all e-mail correspondence. And, of course, you should not delete anything, as you may find a need for it later.

Tip #2: Send e-mail to shed light on people who are missing deadlines

You may find that certain employees involved in the project at the client site are missing deadlines, which, in turn, affects your ability to complete the project on time. To address these issues, it’s best to confront the employee through e-mail correspondence — once again, for the benefit of keeping records. Your correspondence should be diplomatic and politically correct, but you should also use it to force your adversaries to address specific job-related issues, even though this may not cast them in a favorable light.

Keep in mind, however, that this method is not always effective. Some people will see through this tactic and will respond to your e-mails with dissemblance, giving the appearance of their desire for teamwork — while maintaining their adverse behavior toward you.

But there are situations in which this method works well. I chose this course of action recently during a stint as a program manager with a communications conglomerate. I deliberately continued to ask a difficult employee for the status on due dates that had been missed, I questioned issues that were addressed late in the project, and I asked about items that I knew were in this person’s area of responsibility. It worked like a charm. Oftentimes, if you give them enough rope, they will hang themselves.

Tip #3: Maintain your professional composure

Often, the advice that sounds the most obvious is the most difficult to follow in real life. Avoid any animosity or anger toward people who are deliberately working against you. Don’t let their errant behavior influence yours. It will only serve to be your downfall and put you at their level. A reaction from you is what they are usually after. Maintain a professional approach — especially around coworkers who may be friends of your adversaries.

Tip #4: Allow actions to speak louder than words

Perform only what is within your job responsibilities but be willing to go that extra mile. It can only help to solidify your position with the company and make it that much more difficult for the troublemakers to usurp you. Here again, in doing so, you run the risk of coming across as an overachiever. This won’t score you any points with the “in” crowd, but you weren’t hired to be popular. You were hired because your record showed a clear propensity for accomplishing goals and for getting things done.

Tip #5: If you can’t beat them, try to befriend them

If the situation doesn’t appear to be getting any better, but you feel the job is worth salvaging, try a new approach. Make an effort to ingratiate yourself with the troublesome individuals and reason with them. Ask them specifically what it is that you may have done to draw their disfavor and how you can make your relationship better for the sake of the company.

Don’t discuss their rude and unprofessional behavior, because this can be counterproductive. It may be a hard pill to swallow, but you need to ask yourself if sacrificing a little dignity might be worth what you may gain in the long run.

I don’t advise going directly to the employee’s supervisor. Remember that the people you have a complaint against are permanent employees. It’s infinitely easier for the company to select the fast-and-easy way to eliminate complaints by getting rid of you. Don’t shoot yourself in the foot.

If you must resign, leave with a good attitude

If all else fails and you still find yourself on the slippery slope out the door, be confident in the fact that you did the best job you could under difficult circumstances. Regroup and learn from the experience. Using those lessons to your advantage down the line ensures that you will always come away from every job with something useful.