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

# Environments and previews

> Projects, workspaces, environments, and Capsules: separate app environments for branches

Monk organizes deployments into **projects** and **environments**. **Capsules** add preview environments per branch on top of that.

## Projects, workspaces and environments

* A **project** is an app as Monk's platform knows it. It belongs to your personal account or to an organization.
* A **workspace** is a folder on someone's computer, usually a checkout of the repository, bound to a project. Several people can have workspaces for the same project. The web dashboard lists them under the project's Workspaces tab.
* An **environment** is a named deployment of the project, such as `dev`, `staging` or `production`. Each environment is linked to a cluster, and several environments can share one cluster.

When you deploy to an environment, the environment decides which `MANIFEST` entry and which images are used, and which cluster receives the deploy. Secrets can be scoped to a project or environment, so `staging` and `production` get different values. See [Security](https://docs.monk.io/concepts/security.md).

```
/monk deploy to staging
```

Monk can list the environments for your workspace, select one, and delete one. Deleting asks for approval. A project can only be deleted once it has no environments left. To link a cluster to an environment, Monk binds the cluster. See [Clusters and clouds](https://docs.monk.io/concepts/clusters-and-clouds.md).

Environments and projects can carry **instructions**: guidance your coding agent reads before it works there, such as "use the smallest instance type in staging". They are guidance, not enforcement. See [Teams and access](https://docs.monk.io/concepts/teams-and-access.md).

## Capsules (preview environments)

Capsules give each branch its own app environment. When you push a branch, a GitHub Actions workflow deploys it to a capsule of its own, either a new cluster or a pool of nodes on an existing cluster. When its pull request closes, the workflow removes the capsule. Each capsule is an environment of the project, named after its branch, and the web dashboard lists them under the project's **Previews** tab rather than with the other environments.

See [Capsules](https://docs.monk.io/concepts/capsules.md) for the modes, the lifecycle, schedules and secrets.

## Related

> [card] [Capsules](https://docs.monk.io/concepts/capsules.md)
>
> How preview environments work

> [card] [CI/CD](https://docs.monk.io/guides/cicd.md)
>
> Deploy one branch to a fixed cluster

> [card] [Clusters and clouds](https://docs.monk.io/concepts/clusters-and-clouds.md)
>
> Clusters, node tags and binding

> [card] [Teams and access](https://docs.monk.io/concepts/teams-and-access.md)
>
> Who can deploy where


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