Shift or Wedge
Noise can originate from the unit if it's too close to the wall. Check the clearance. If it's a simple vibration caused when the compressor turns on, it might be as easy as shifting the position of the unit to the right or left to alleviate noise. The noise might be coming from loose window trim. Nail the molding firmly in place or, in a pinch, tap a small wedge behind it. Sometimes all it takes is a strategically placed, folded matchbook cover to stop the noise.
Trim and Paper
Trim is notorious for causing vibrations. Use a screwdriver to tighten all of the screws holding trim or the faceplate on the unit. If you're staying at a hotel or some other location and the noise is driving you mad, you still have some options. Check knobs, levers or anything else on the unit. If you find something loose, wedge it with a small piece of folded paper.
The Biggest Fan
Fans are a major source of noise. It might be caused from a bent blade coming into contact with insulation or touching the side of the unit. Unplug the unit and locate the screws securing the cover on the unit and remove them to reveal the fan. Look for twigs, leaves or anything that could be in contact with the blades and remove it. Check the blades if possible, by giving the fan a spin with your fingers. If one of them is bent, it could be coming into contact with other objects. Blades are thin, and easy to bend straight again. If it's badly bent, replace it with a new one.
Things can loosen due to the natural vibration of the unit. Loose compressor or housing bolts, or bolts holding panels, are a source of noise. With the cover removed, check bracket and housing bolts. Tighten them as needed to quiet the noise. Motors that need lubrication make noise. Some of them have lubrication ports for lightweight -- typically 10-weight -- oil that will quiet them down. If your air conditioner is new and it makes noise, it might be a stray bolt, spare part, packaging material or other object loose somewhere in the housing. Check for loose objects and remove them.
Coil fins are the comblike ridges on the outside of your AC unit. They serve to expel heat from the machine and are easily bent by handling -- or when something strikes them. They also tend to collect dirt. If the coil fins are bent or dirty, they can cause the unit to emit a humming noise. They can be straightened and cleaned with a fin comb. Insert the teeth of the fin comb between the coil fins and slide it to straighten bent fins.