---
title: "How while works: projects, environments and while.yaml"
url: https://while.sh/en/docs/get-started/how-while-works/
updated: 2026-11-03
---

# How while works

while deploys the apps your agent builds, and leaves the decisions that matter to a person. Here are the ideas to know, on one page.

## Your agent acts, a person decides

Your agent connects to while over MCP, with your permissions, never more. It deploys, creates databases, reads the logs and fixes things.

Sensitive actions wait for a person: deleting a database, opening an app to the internet, connecting an external API, or shipping to production if your organization requires it. while tells your agent, and sends you the link to approve.

## Organization, projects and environments

Your organization brings together your members, your projects and your invoice. A project is an app: its code, its services, its databases and its jobs.

Each project has its production, and previews to try a new version before it goes to production. Each environment has its own variables, its own databases and its own address: a preview never touches production data.

## while.yaml describes your app

A file at the root of your app, while.yaml, says what it needs: its services, its databases, its caches, its buckets, its jobs, its domains and who can open it. Your agent writes it, and while does the rest.

Before applying a change, [the plan](/en/docs/building-blocks/plan/) shows what will change, building block by building block, and what it changes per month. The full while.yaml schema is at `https://app.while.sh/schema/while.v1.json`.

## Every version is kept

Each deployment builds a frozen version, tested during its build. The previous one stays ready: it comes back in a second during the 30 minutes after a deployment, and in a few seconds after that.

## Your data is backed up

Each database is backed up continuously and every day, and the daily backup of a production database is tested by a real restore. Your agent restores a database to a precise moment in the last 14 days. Your apps and your data are hosted in France, by Nextmap.

## Each project has its budget

Each project has a monthly budget, €20 by default, which you change whenever you want. You are notified when the spending forecast for the month reaches 80%, then 100% of the budget. A change that would exceed the budget waits for your approval, and your apps already live keep running.

## Next steps

- [Your first deployment](/en/docs/get-started/first-deployment/)
- [What your app must follow](/en/docs/get-started/the-while-contract/)
- [All building blocks](/en/docs/)
