> ## Documentation Index
> Fetch the complete documentation index at: https://evalgate.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Publish and roll back a prompt

> Promote an approved version, then undo safely.

# Publish and roll back a prompt

Protected environments resolve approved, exact versions. Rolling back means
pointing the alias at a previous approved version — never at a draft.

## Publish a version

1. Open the prompt and pick an approved version.
2. Click **Publish to environment**.
3. Choose the environment (for example, `production`).
4. Confirm. The alias now resolves that exact content hash.

<img src="https://mintcdn.com/evalgate/c7l4ztAi8W3wgmvV/help/images/publish-prompt-dialog.png?fit=max&auto=format&n=c7l4ztAi8W3wgmvV&q=85&s=fafc1ef336b8257286aa97f560a6deca" alt="A screenshot of the publish dialog with the production environment selected." width="2160" height="1350" data-path="help/images/publish-prompt-dialog.png" />

<Note>
  Publishing is append-only. The previous version stays in history and can be
  re-pointed to at any time.
</Note>

## Roll back

1. Open the prompt's **History** tab.
2. Find the last known-good version.
3. Click **Publish to environment** on that version.
4. Confirm. The alias now resolves the older version.

<img src="https://mintcdn.com/evalgate/c7l4ztAi8W3wgmvV/help/images/publish-prompt-rollback.png?fit=max&auto=format&n=c7l4ztAi8W3wgmvV&q=85&s=7b2c8157b7e6a5099bc6108548b43288" alt="A screenshot of the History tab with a previous version being re-published." width="2160" height="1350" data-path="help/images/publish-prompt-rollback.png" />

## What you cannot do

* You cannot edit a published version. Versions are immutable.
* You cannot point a protected alias at a draft.
* You cannot delete a version that a deployment, evaluation, or trace still
  references.

## Up next

Build the scorer that decides pass/fail: [Create a scorer](../scorers/create-scorer).
