# Undo and redo canvas edits

Undo or redo recent node, connection, and agent preset changes.

Undo and redo reverse recent canvas edits, including node, connection, and agent preset changes. Canvas history is kept in memory.

## Undo an edit

1. Make sure the canvas has keyboard focus.
2. Press <kbd>Ctrl</kbd> + <kbd>Z</kbd> on Windows or Linux, or <kbd>Cmd</kbd> + <kbd>Z</kbd> on macOS. You can also choose **Undo** from the command palette.

## Redo an edit

1. Press <kbd>Ctrl</kbd> + <kbd>Shift</kbd> + <kbd>Z</kbd> or <kbd>Ctrl</kbd> + <kbd>Y</kbd> on Windows or Linux. On macOS, use <kbd>Cmd</kbd> + <kbd>Shift</kbd> + <kbd>Z</kbd> or <kbd>Cmd</kbd> + <kbd>Y</kbd>.
2. You can also choose **Redo** from the command palette.

> **Tip:** Moving or resizing a node is one history step after you finish the drag.

> **Limit:** History is not saved and clears when you switch workspaces. Panning and zooming are not undoable. Undoing a deleted terminal creates a new process; undoing a deleted note node leaves its Markdown file in place.

Source: https://trymao.dev/docs/canvas-basics/canvas-undo-redo
