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

# Releases and Rollbacks

> Promote named releases when things are good, and roll back to a prior deploy when they are not.

Use a release when you want to label and promote the current live state. Use a rollback when you want to move traffic back to an earlier deploy.

## Start With Deploy History

```bash theme={null}
floo deploys list --app my-app
```

Deploy history tells you what is live now and which deploy IDs are valid rollback targets.

## Promote a Release

Promote takes the **latest live dev deploy** and deploys it to production. Optionally tag it:

```bash theme={null}
floo releases promote --app my-app
floo releases promote --app my-app --tag v1.2.0
floo releases list --app my-app
floo releases show <release-id> --app my-app
```

You do not specify a deploy ID — promote always acts on the current live dev deploy. Choose this flow when dev is healthy and you want a stable production release.

## Roll Back to a Previous Deploy

Use rollback when the live deploy needs to be replaced immediately:

```bash theme={null}
floo deploys rollback my-app <deploy-id>
floo deploys rollback my-app <deploy-id> --force
```

The rollback target must come from `floo deploys list --app my-app`.

## Which One Should You Use?

| Use case                             | Command                                   |
| ------------------------------------ | ----------------------------------------- |
| "This deploy is good; tag it."       | `floo releases promote`                   |
| "This deploy is bad; go back."       | `floo deploys rollback`                   |
| "I need the build/build logs first." | `floo deploys list` + `floo deploys logs` |

## Recommended Workflow

```bash theme={null}
floo deploys list --app my-app
floo deploys logs <deploy-id> --app my-app
floo releases promote --app my-app --tag v1.2.0
```

If production is unhealthy:

```bash theme={null}
PREV=$(floo deploys list --app my-app --json 2>/dev/null | jq -r '.data.deploys[1].id')
floo deploys rollback my-app "$PREV" --force --json
```

## Dashboard Surface

The shipped app detail view has a Releases tab for promoted releases. The CLI remains the primary surface for choosing rollback targets and executing the rollback itself.
