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

# 2.1: Upgrade guide

> Version-specific changes and preserved upgrade instructions.

> [!NOTE]
>
> Historical upgrade notes. Check the [maintenance policy](https://formbricks.com/docs/self-hosting/advanced/release-maintenance-policy.md)
> for support status. These instructions describe this release, not the current installation defaults.

Read the notes for every version you cross. Use the [upgrade checklist](https://formbricks.com/docs/self-hosting/advanced/upgrade.md)
to plan backups, service interruption and recovery. Old commands using `latest` or `stable` must be
resolved to the historical target release before use; they must not jump to today's release.

Before the Docker commands below, edit the `formbricks` service's `image` in your existing
`docker-compose.yml`. Replace `latest` with your exact published **2.1.x** tag, for example
`ghcr.io/formbricks/formbricks:v2.1.0` for the initial release. These historical GHCR tags include `v`. Confirm the selected tag with
`docker compose config --images` before running `pull` or `up`; keep your existing volumes and settings.

Formbricks v2.1 introduces more options for creating No-Code Actions and improves the self-hosting experience with a new onboarding process for fresh instances.

> [!NOTE]
>
> To improve the user experience and simplify setup for self-hosting instances, we are transitioning to a single organization model. This change allows self-hosts to manage their instance centrally and more easily control access. A new permissions system will also be introduced soon, providing more granular control over projects and resources within an organization.
>
> If you've previously created multiple organizations, you can still switch between them in the UI, but creating new organizations will no longer be possible.

### Steps to migrate

This guide is for users self-hosting Formbricks using our one-click setup. If you are using a different setup, you may need to adjust the commands accordingly.

To follow these steps, please navigate to the Formbricks folder where your `docker-compose.yml` file is located.

* **Backup your Database**: This is an essential step. Please ensure that you back up your database before proceeding with the upgrade. You can use the following command to back it up:

```bash theme={null}
docker exec formbricks-postgres-1 pg_dump -Fc -U postgres -d formbricks > formbricks_pre_v2.1_$(date +%Y%m%d_%H%M%S).dump
```

> [!NOTE]
>
> If you run into “No such container”, use `docker ps` to find your container name, e.g.
> `formbricks_postgres_1`.

> [!NOTE]
>
> If you prefer storing the backup as a `*.sql` file remove the `-Fc` (custom format) option. In case of a
> restore scenario you will need to use `psql` then with an empty `formbricks` database.

* Pull the selected version of Formbricks:

```bash theme={null}
docker compose pull
```

* Stop the running Formbricks instance & remove the related containers.

```bash theme={null}
docker compose down
```

* Restarting the containers with the selected version of Formbricks:

```bash theme={null}
docker compose up -d
```

* Now let's migrate the data to the latest schema:

> [!NOTE]
>
> To find your Docker network name for the Postgres database, run the following `docker network ls`

```bash theme={null}
docker pull ghcr.io/formbricks/data-migrations:v2.1.0 && \
docker run --rm \
  --network=formbricks_default \
  -e DATABASE_URL="postgresql://postgres:postgres@postgres:5432/formbricks?schema=public" \
  -e UPGRADE_TO_VERSION="v2.1" \
  ghcr.io/formbricks/data-migrations:v2.1.0
```

Once the migration script runs successfully, your data will be migrated to the latest schema. The script is designed to run safely multiple times, so you don’t need to worry if it’s executed more than once. After completing the migration, you can continue to access your Formbricks instance at the same URL as before.

* That's it! Once the migration is complete, you can **now access your Formbricks instance** at the same URL as before.

### Changes in environment variables

* **SIGNUP\_DISABLED** is now deprecated. Self-hosting instances have signup disabled by default, and new users can only be invited by the organization owner or admin.

* **DEFAULT\_TEAM\_ID** has been renamed to **DEFAULT\_ORGANIZATION\_ID**.

* **DEFAULT\_TEAM\_ROLE** has been renamed to **DEFAULT\_ORGANIZATION\_ROLE**.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.