# Move from Open Source to the Enterprise Plan

Source: https://agenta.ai/docs/self-host/upgrade-and-migrate/oss-to-ee-switch

From v0.131.1, open source and Enterprise installs run the same images. There is no switch of images or databases. A [license key](https://agenta.ai/docs/self-host/reference/license-keys.md) decides the plan.

## If your instance runs v0.131.1 or later

Add a license key. The instance admin selects **Add a license key** under **Settings > License** and pastes it, or you set `AGENTA_LICENSE_KEY` and restart the `api`, `worker-queues` and `worker-streams` containers. See [Add a license key](https://agenta.ai/docs/self-host/reference/license-keys.md#add-a-license-key).

- The [free key](https://agenta.ai/docs/self-host/reference/license-keys.md#get-a-free-registration-key) removes the limit of 1 project per organization.
- A paid key turns on the enterprise features and removes the limit of 1 organization per instance. To get one, [talk to us](https://agenta.ai/contact).

## If your instance runs an older version

1. Take a dump of your core and tracing databases.
2. Pull the new images and restart, with your existing compose files, Helm values or Railway template. See [Upgrading to 0.131.1](https://agenta.ai/docs/self-host/upgrade-and-migrate/upgrading.md#upgrading-to-0131-1).
3. Add a license key, as above.

On the first start, the migration job adds the Enterprise tables to your open source database and keeps every member's access to their projects. You do not run any migration or membership command yourself.

If your instance runs a version older than v0.104.0, upgrade it to the latest 0.129.x release first. The migration job of v0.131.1 stops on an older database before it changes anything.

:::warning Do not change `AGENTA_LICENSE`
`AGENTA_LICENSE` picks the default database names, not the plan. Setting it to `ee` on an open source install points the install at other, empty databases (`agenta_ee_*`), and it looks as if its data is gone. Keep the value you have.
:::

## What changes without a key

An upgraded instance with no key runs on the Community plan. Existing projects and organizations stay. A new project in an organization that already has one, and a new organization, are refused. See [Upgrade an open source instance](https://agenta.ai/docs/self-host/reference/license-keys.md#upgrade-an-open-source-instance).
