# Approve a release, discard it or roll back

> Publish or throw away a release waiting for approval, and put an earlier release back when a deploy goes wrong.

Source: https://veldhost.eu/docs/release-approval-and-rollback

Last verified: 2026-11-12

With the [CI/CD add-on](https://veldhost.eu/docs/ci-cd-add-on), each deploy from Git is built, tested and then held until someone approves it. This page covers that decision, and how to go back to an earlier release afterwards.

## Before you start

Approving, discarding and rolling back to a release need the account owner, an administrator or a developer ([Roles and permissions](https://veldhost.eu/docs/roles-and-permissions)). Other people see the waiting release, but not the buttons.

## Approve or discard a waiting release

> **Note:** on a Laravel app, a waiting release has not touched your database yet. Its migrations run when you approve it, just before the switch; discarding it leaves the database as it is.

1. Open [Sites](https://manage.veldhost.eu/portal/sites) → your site → **Deploys**. A held release shows at the top as **Waiting for your approval**, with its number (for example `r-14`) and its risk.
2. Read **What is in it** (the commits) and **How risky is it**. **Build log** has the full output, including your tests.
3. Press **Approve & publish r-14**. Your site switches to the release in about a minute. **Recent deploys** shows *publishing*, then *live now*, and the **Live now** strip names who approved it.
4. Or press **Discard it** and confirm with **Discard it**. The built release is deleted and your site stays exactly as it is. Deploy again whenever you like.

Only one release waits at a time. If a newer deploy finishes building before you decide, it replaces the waiting one, which is marked *discarded* in **Recent deploys**.


## What the risk score means

The score is a weighted count of facts about the release, not a prediction. Each fact that moved it is listed, so you can judge it yourself. It is worked out once, when the release is built, and does not change afterwards.

What raises it:

- a database migration is added or changed (this weighs heavily, because rolling back files cannot undo it)
- many files change
- the packages your site depends on change
- configuration changes
- many separate commits go out at once
- your last deploy failed
- nothing has been deployed successfully yet, or the last working deploy was over a month ago

What the panel lists as lowering it: only a few files change, or you deployed this site successfully in the last week.

The panel shows **Low risk**, **Moderate risk** or **High risk** with the score. **Risk unknown** means we did not get a list of what changed (for example on the first deploy from Git), so we could not look. It does not mean the release is safe.

## Roll back to an earlier release

When your deploys from Git show a number in the **Release** column (`r-13`), the recent releases are still on our servers and you can switch back to one of them.

> **Caution:** rolling back replaces the live code only. Your database stays as it is, so older code then runs against a database a later release may have migrated.

1. Open [Sites](https://manage.veldhost.eu/portal/sites) → your site → **Deploys**.
2. On the **Live now** strip, press **Roll back to r-13** to go back to the release before the live one. For an older release, open the **⋯** menu on its row in **Recent deploys** and choose **Roll back to r-12 (files only)**.
3. Confirm with **Roll back the files**.

Your files return to that release within a minute. A rollback needs no approval, even with the CI/CD add-on on. It starts only when no other deploy is running or waiting; otherwise you are asked to finish that one first.

**What a rollback puts back:** your site's code, exactly as that release was built, dependencies included.

**What it leaves alone:** your database, your environment variables, and files your app keeps between releases, such as uploads in Laravel's `storage/`.

A release without a number in the **Release** column (for example a file upload) can't be rolled back to, and older releases are removed from our servers over time. For those, restore a backup.

## Roll back files and database

When a deploy changed your database too, go back to the snapshot we take just before every deploy from Git.

> **Caution:** This replaces your whole database with the snapshot. Anything written since that deploy, such as orders, sign-ups or comments, is lost. We snapshot the current state first, so you can restore that if you change your mind.

1. Open [Sites](https://manage.veldhost.eu/portal/sites) → your site → **Deploys**.
2. Open the **⋯** menu on the deploy's row and choose **Roll back files & database**.
3. Confirm with **Roll back files and database**.

This is a backup restore: it needs permission to restore backups, and works as described in [Backups & one-click restore](https://veldhost.eu/docs/backups-and-restore).

## With the API or an AI assistant

`GET /api/v1/sites/{slug}/deploys` (or `list_deploys`) marks each deploy with `awaiting_approval` and `can_roll_back_to`. Then call `POST /api/v1/sites/{slug}/deploys/{id}/approve`, `/discard` or `/rollback`. Your token needs the **deploy** scope, and you need one of the roles above. `approve_release` and `rollback_release` first tell your assistant what will happen and ask you to confirm.

## Related

- [The CI/CD add-on](https://veldhost.eu/docs/ci-cd-add-on)
- [Build steps](https://veldhost.eu/docs/build-steps)
- [Backups & one-click restore](https://veldhost.eu/docs/backups-and-restore)
- [API reference](https://veldhost.eu/docs/api-reference)