The complete WoW macro guide

The only macro guide you need: what macros can do, how to write one, and the patterns that survive every expansion.

What a macro actually is

A macro is a saved text command that fires client actions in order when you press it. You write it in the macro window (/macro), give it an icon, and bind it to a key or action bar button. No addons required, no third-party anything. The system has been in the client since the game launched, and it is unchanged in the WoW: Forever beta.

Macros earn their place in two situations: when one button needs to do different things depending on context, and when you are tired of hitting two buttons in a fixed order. Everything in a macro is one of three ingredients: a command (what fires), a conditional (when it fires), and a separator (; chains fallbacks together).

A macro you can use right now

The classic "one button heals friends and damages enemies" pattern. Built on the two conditionals you will use more than any others: help (friendly target) andharm (enemy target).

#showtooltip/cast [@mouseover,help,nodead] Flash Heal; [harm] Smite; Flash Heal

Read it as: if I'm mousing over a living ally, heal them. Otherwise, if my target is an enemy, smite it. Otherwise (no useful mouseover, no harmful target), heal myself. Three behaviors, one key, zero retargeting. Swap Flash Heal and Smite for your own healing and damage spells and the pattern works for any class.

The anatomy of a macro

  • #showtooltip displays the tooltip of the first spell the macro can actually cast, instead of a question mark.
  • /cast is the command you will press the most. It casts the spell you name.
  • [brackets] hold conditions. If the conditions inside are false, the cast is skipped and the next section is tried.
  • ; separates fallback sections. The client walks the chain left to right and fires the first section whose conditions pass.

The comma inside brackets means and. The semicolon between sections meansor, if the last one didn't fire. That pair is the whole of macro logic.

Six commands you will live in

The full reference is on the macro commands page. These six cover most real macros:

  • /cast: cast a spell. Takes conditionals.
  • /castsequence: step through spells in order, one per press.
  • /targetenemy: target the nearest enemy. The basis of tab-free gameplay.
  • /stopcasting: cancel the current cast. The interrupt-enabler.
  • /use: use an item, trinket, or racial on a target.
  • /startattack: start auto-attacking without interrupting anything.

Rules that never change

  • 255 characters per macro. The editor counts. If a macro is longer, you are trying to do too much in one button, and the fix is usually two buttons.
  • Macros do not bypass the global cooldown. They fire client actions, which respect everything the game respects. A macro cannot cast two spells simultaneously, and it cannot chain casts faster than the GCD allows.
  • Conditionals are evaluated per press. There is no "memory" between presses except the state of the game itself: target, stance, form, cooldowns. If a macro needs remembered state, use a castsequence.
  • Anything a human can't do, a macro can't either. If the game would refuse the action, the macro simply skips it and moves to the next section.

Where to go next

Start with macros conditionals (the bracket language), then modifiers (one button, several spells), then the technique pages: mouseover for healers and interrupt duty, lazy macros for the set-and-forget bind, andcastsequence for rotation-in-a-button. Classic players should head to the Classic hub.

Questions people ask

Are WoW macros against the rules?+
No. The macro system is built into the World of Warcraft client and has been since vanilla. Making macros is normal gameplay. Rules about automation apply to third-party hardware and software that play the game for you, which is a different thing entirely.
Do macros work in WoW Classic?+
Yes. Classic runs the same client macro system with the same commands, conditionals, and modifiers. A few conditionals that exist in modern WoW were added over time, so the classic pages on this site use era-correct syntax like [target=unit] instead of the newer [@unit] shorthand.
Do my macros carry over between expansions?+
The macro files carry over. Individual macros stop working when the ability they call gets renamed, removed, or moved to a different spec. The patterns on this site are written so the fix is a one-word change, not a rewrite.
Can macros play the game for me?+
No. A macro fires commands when you press it. It cannot make decisions, watch timers, or keep a rotation going without you. If you want automatic behavior, that is the line where addons (and eventually addon restrictions) take over. See macros vs addons.
What is the character limit on a macro?+
The macro window accepts 255 characters per macro. It sounds tight. In practice most good macros are one short line, and multi-action macros are two or three.