Stack

The stack is the game zone where spells and abilities are put when they are played and where they wait to resolve. The stack system allows players to "respond" to the actions of other players before those actions take full effect, enabling interactive gameplay even with "instantaneous" effects.
==Description==
Spells and abilities are put on top of the stack as the first step of being played, and are removed from it as the last step of resolving. 
Any spell or ability that uses the stack can be "responded to" by all players, meaning players have a chance to play spells and abilities with it still on the stack. Since the stack resolves in order from top to bottom, those spells and abilities will resolve before the spell they were played "in response" to ("last in, first out"). Spells and abilities on the stack resolve one at a time, with a chance for each player to play spells and abilities in between each resolution. Actions that do not use the stack, such as paying costs, playing mana abilities, or turning a face-down creature with morph face-up, cannot be responded to.
==Rules==
==Actions==
===Actions that use the stack===
Spells, activated abilities, and triggered abilities become objects on the stack instead of resolving immediately. As described above, this means that responses may go above them on the stack, allowing those to resolve before the original spell or ability. 
However, the single action of casting a spell or activating an ability does not use the stack, only the resolution of that spell or ability uses it. For example, if the player with priority declares they are casting <c>Lightning Bolt</c>, the opponent may respond by giving a creature protection from red before it deals damage, but it is too late to force the player to discard the Bolt before it's even cast.
===Actions that don't use the stack===
Actions that don't use the stack can't be responded to by performing other actions before the first action actually happens. However, some actions may be part of a larger process that does use the stack, such as resolving a spell (which could be responded to before the spell starts resolving), or may be part of a process which places an object on the stack, such as casting a spell (in which case the spell can be responded to, but the actions taken while casting it cannot be).
Turn-based actions happen automatically upon reaching specific parts of a turn, and don't use the stack. Some of these actions are technically done by the game itself rather than players, with the players simply manipulating their cards to reflect the new game state.
* Untap step: Untapping, as well as phasing and day and night transitions if applicable
* Draw step: Drawing a card
* Main phase: Sagas advance one more step
* Combat phase: Declaration of attackers, blockers, and various damage assignments
* Cleanup step: Discarding to hand size; clearing damage; ending "until end of turn" effects
* All steps: Emptying unused mana from the mana pool; ending effects that last until that step
Special actions are certain intentional actions a player may take when they have priority. By far the most common of these is playing a land. There are also a number of card abilities that enable special actions as well, like morph and foretell, as well as non-keyword abilities on several cards. Conspiracy Draft and Planechase games allow two more special actions.
Activating a mana ability is not considered a special action, but it follows similar rules if activated on its own (rather than while paying a cost).
Paying a cost can never be responded to, even if the actions taken as part of that cost are, in other cases, part of effects that do use the stack. For example an activated ability that includes the very common cost of tapping a permanent can be activated and tapped immediately, and an opponent would not be able to respond with an instant that destroys the permanent first - although they could respond to the ability on the stack later. Mana abilities can also be activated during cost payment (and many other times) without the possibility of response.
Actions taking during the resolution of a spell also don't use the stack, preventing responses in between two sequential spell abilities. However a spell can generally be responded to before any of its abilities start resolving.
Replacement effects are applied without using the stack. However, the continuous effects that create them are usually known ahead of time, and most effects that are replaced do use the stack, so those effects can be responded to before replacement effects start to apply. This includes actions that happen "as" other actions take place, for instance daybound and nightbound cards transforming as day and night transitions occur.
===Damage and the stack===
Damage itself does not use the stack. However, many effects that would cause damage do use the stack, and can be responded to. Combat damage can't be responded to using the stack, but effects can affect damage pre-emptively simply by playing them before the combat damage step begins (during the declare blockers step). Many effects that interact with damage do so as replacement effects: before the damage occurs, stack actions resolve to set up a replacement effect, then when the damage would occur, it is automatically modified by the replacement effect without using the stack.
Between Sixth Edition until Magic 2010, damage events, notably combat damage, existed on the stack before damage was actually dealt. This gave an opportunity for players to respond to prevent damage, but also allowed unintuitive interactions, like removing a creature that had unresolved damage on the stack, which allowed the creature to deal damage despite being absent from play. When this was removed, damage interactions changed to replacement effects, and the institution of damage assignment order made combat predictable enough to use the stack to set up the response to damage before the combat damage step itself.
==Trivia==
* In flavor terms, the stack is the point when a spell is materializing, the stage between your mind and external reality.
* The stack was featured as rules card 7 of 9 in the Magic 2011 set.
* Magic uses the term "stack" in the same way it is used in computer science. They both follow the last in, first out (LIFO) rule of behavior.
==References==
==External links==
*Essential Magic, The Stack
*Priority, Stack, Turn structure