Vanish is a core rogue ability learned at level 34. It allows the rogue to disappear from sight, entering an improved stealth mode for three seconds; it also breaks movement impairing effects. All aggroed mobs on the rogue will exit combat and return to their original locations or turn to other players if the rogue is in a party. During the three seconds any damage the rogue takes will not break stealth. After the three seconds, the rogue will enter normal [Stealth].
Note that this ability is not intended to be used to escape damage; [Cloak of Shadows] is intended for that.
Back in the days Vanish allowed avoiding getting hit by mid-air spells. Later on you could even negate instant cast spell effects due to short amount of time of immunity Vanish provided, which was added to the game because of rogue players complains about Vanish being randomly broken. This was changed in early Cataclysm after Vanish was reworked into providing unbreakable 3 second Stealth.
Casters will be able to AoE you when you Vanish. Use Cloak of Shadows or [Sprint] or strike with [Cheap Shot] or potentially [Sap] (if they are out of combat already) to avoid this.
It may be useful to use Vanish if you are near death and the enemy is low on health. Vanish and Cheap Shot will often catch your enemy off guard and let you regain control.
During boss fights in raids or groups vanish is useful if the rogue draws aggro from the main tank. The mob will not reset as long as somebody else still has aggro, plus a new Stealth attack can be started.
It may be too late if you save Vanish until you have aggro. Use Vanish early into the fight (boss @ 70%) to drop all aggro. You will save energy that would have been spent on [Feint].
If you play on a PvP server, and you see a ?? of the other faction rolling up, you can Vanish and Sprint away, and hope for the best. With how Vanish raises your Stealth by a great deal, you may just get away without a corpse run.
During a boss fights, wait for 50~ energy before vanishing, so you can immediately [Garrote] and continue DPS, vanishing at low energy means you will either waste time for you energy to tick up before you can attack, or have to cancel Stealth and miss out on this special attack.
Patch 2.4.0 (25-Mar-2008): Abilities that can be used while stealthed, without breaking stealth, can now be cast without breaking Vanish when used at the same time.; This ability will no longer sometimes cause the UI to display Shadowmeld as active when it has been cancelled.
Patch 2.0.3 (09-Jan-2007): Resisted spells will no longer break "Stealth"/"Vanish".
/Patch 2.0.1 (05-Dec-2006): "Vanish" will now properly un-target the Rogue from the attacker when the attacker is in the same party.
Patch 1.11.0 (20-Jun-2006): Canceling your Stealth aura while Vanish is running will now cause Vanish to be canceled as well.
Patch 1.8.0 (10-Oct-2005): Fixed a bug where the Chilled effect caused by Ice Armor/Frost Armor was not removed properly when vanishing.
Patch 1.5.0 (2005-06-07): Should be a lot more responsive when used to avoid incoming attacks.