---
title: "Layout version history"
description: "Every save of an email layout is kept. Preview an older version and restore it."
canonical: "https://docs.workflow-transactional-email.app/layout-version-history"
---

# Layout version history

Every time a layout is saved, the app keeps a version: the layout and all its languages as they were at that moment. The app keeps the newest 25 versions of each layout. Connect GitHub and every version is also kept in your repository, so history is unlimited, and editing a layout's file in the repository updates the layout in the app. See [Keep unlimited layout history on GitHub](https://docs.workflow-transactional-email.app/layout-history-on-github.md).

Versions are created when you save in the editor, save a translation, change the layout through the API or an AI assistant, or restore a version.

## View and restore

1. Open the layout and click **Version history**.
2. Click **View** on a version to see its subject and a preview.
3. Click **Restore version**.

The layout and all its languages go back to that version, and Shopify Flow uses it from the next email on. Your current layout stays in the list as a version, so a restore can be undone the same way.

> [!WARNING]
> Version history keeps the layout, not your media library. An image or file you deleted from the media library since that version is not brought back; replace it after restoring.

## Through the API

`GET /api/v1/email-templates/:id/versions` lists versions and `POST /api/v1/email-templates/:id/versions/:version/restore` restores one. The MCP tools are `list_template_versions`, `get_template_version` and `restore_template_version`.
