Learn › Excel › Undo

Excel undo shortcut: Ctrl + Z

Take back your last action. Press again to go back further.

With voice: turn the sound on to hear how it works. Recorded in Excel for the web; the shortcut works the same in desktop Excel.

WindowsCtrl+Z
Mac⌘+Z

What it does

Ctrl + Z undoes the last thing you did, such as typing, formatting or deleting. Pressing it again goes back one more step. Ctrl + Y does the opposite and redoes what you just undid.

When to use it

Use it whenever you make a mistake: deleted the wrong column, applied the wrong format, or pasted over data. It is the safest way to experiment, because you can always step back.

How to do it

  1. Do something you want to take back.
  2. Press Ctrl + Z (on a Mac: Command + Z).
  3. Press Ctrl + Y if you change your mind and want it back.
Good to know: The undo history is cleared when you close the file, and some actions, such as running a macro, cannot be undone. Save a copy before big changes.

A quick example

You delete column C by mistake. Press Ctrl + Z and the column is back with all its data and formatting. Press Ctrl + Z five times to go back five actions, or Ctrl + Y to move forward again.

Undo, Redo and Repeat

Ctrl + Z undoes the last action and Ctrl + Y redoes it. When nothing has been undone, Ctrl + Y (or F4) repeats your last action, which saves time when you apply the same format to many ranges. The arrow next to the Undo button on the Quick Access Toolbar lets you jump back several steps at once.

Not working? Check this

  • Undo is grayed out: the history was cleared. Closing the file or running a macro clears it.
  • Some actions cannot be undone, for example deleting a worksheet. Save a copy before big changes.
  • On a Mac use Command + Z, and Command + Y to redo.

Quick answers

What is the shortcut for redo in Excel?

Ctrl + Y on Windows and Command + Y on a Mac. It repeats the action you just undid. If nothing was undone, Ctrl + Y repeats your last action.

Why is undo not working in Excel?

The undo history is cleared when you close the file or run a macro, and some actions, such as deleting a worksheet, cannot be undone. Save a copy before big changes.

How many times can I undo in Excel?

Excel keeps up to 100 steps by default. Press Ctrl + Z repeatedly, or use the arrow next to the Undo button to jump back several steps at once.

More Excel shortcuts

See all Excel shortcuts →