# The toupas command

`toupas` makes the app in a folder on your computer live, and looks after it once it is. It's one file, with no Node.js or Python needed, for macOS, Linux and Windows.

## Install
```
curl -fsSL https://toupas.com/install.sh | sh
```
On Windows, in PowerShell: `irm https://toupas.com/install.ps1 | iex`. Run the same line again to update it.

## Make an app live
In your app's folder:
```
toupas live
```
The first time, it signs you in (in your browser), works out how the app is built and started, writes [toupas.json](/docs/toupas-json), and asks anything only you can answer, such as whether the live app starts with a copy of your local data. Apps with their own server are prepared in Docker on your computer: `toupas doctor` checks it's ready, and `toupas setup docker` installs it.

Run `toupas live` again to update the live app. Only changed files are sent, and the new version replaces the old one only once it has started and answers.

Every command works on the app in the folder you run it in. `--dir <folder>` picks another folder, and `--json` prints one JSON result for scripts and coding agents.

## Your app
| Command | What it does |
|---|---|
| `toupas live` | Make the app live, or update it |
| `toupas status` | Whether the app is live, and how its latest version went |
| `toupas logs` | What the live app printed. `--follow` keeps watching, `--since 1h`, `--grep text` |
| `toupas versions` | The app's recent versions. `toupas versions use <number> --yes` goes back to one; settings and saved data stay as they are |
| `toupas stop --yes` | Take the app offline. Its data is kept |
| `toupas start` | Bring a stopped app back online |
| `toupas rename <name>` | Give the app a new name. Its link stays the same |
| `toupas projects` | Your apps and their links |
| `toupas code get <app>` | An app made in a chat, as code in a folder of your own. Once you run `toupas live` there, chats can't update it any more |

## Settings and secrets
| Command | What it does |
|---|---|
| `toupas env list` | The app's settings. Secrets show as hidden |
| `toupas env set NAME=value` | Add or change settings. `--secret` for passwords and keys: they can't be shown again. `--build-time` also passes it while the app is prepared |
| `toupas env unset NAME` | Remove a setting |
| `toupas env import [.env]` | Save the settings in a .env file, as secrets |

A change restarts the live app with the new settings. If the app doesn't start with them, it keeps running with the previous ones. `.env` files are never uploaded, so keep keys in `toupas env`, not in the code.

Toupas sets `PORT`, `TOUPAS_URL` and the database and storage settings itself; [How apps run](/docs/runtime-contract) lists them all.

## Data and files
| Command | What it does |
|---|---|
| `toupas db` | The live app's Postgres database: [Database](/docs/database) |
| `toupas storage` | The live app's files: [File storage](/docs/file-storage) |
| `toupas dev db` | A database on your computer that matches the live one |
| `toupas dev storage` | File storage on your computer, like the live one |

## Links
| Command | What it does |
|---|---|
| `toupas links` | The app's links. `links main <link>` picks the main one |
| `toupas subdomain set <name>` | A custom name on toupas.app |
| `toupas domains add <domain>` | Your own domain |

More in [Links and domains](/docs/links-and-domains).

## Account and plans
| Command | What it does |
|---|---|
| `toupas usage` | What your account uses: RAM and storage |
| `toupas billing` | Your plan, add-ons and payments. `billing open` pays in your browser |
| `toupas activate` | Move this app from its free trial to your plan |
| `toupas free` | Make this website your free website, online with no plan |
| `toupas showcase add` | List the app on [toupas.com/showcase](/showcase) (Toupas checks it first) |
| `toupas login`, `toupas logout`, `toupas whoami` | Sign in, sign out, and who you're signed in as |

## This computer and your agents
| Command | What it does |
|---|---|
| `toupas doctor` | Check this computer is ready to make apps live |
| `toupas setup docker` | Install Docker Desktop, which apps with their own server need |
| `toupas init --agents` | Let Claude Code, Codex and Cursor use Toupas: [Coding agents](/docs/coding-agents) |
| `toupas mcp` | The Toupas tools for coding agents. Agents start it themselves |
| `toupas runtimes` | The languages Toupas runs apps in |

## Options for `toupas live`
| Option | What it does |
|---|---|
| `--prebuilt <folder>` | Make this folder live as it is, without preparing the app (static sites) |
| `--no-build` | Skip the build and use the existing output folder (static sites) |
| `--copy-local-data` | The first time: the live database starts with a copy of your local data |
| `--start-empty` | The first time: the live database starts empty |
| `--use-toupas-storage` | The app has its own S3 storage: use Toupas file storage instead |
| `--keep-own-storage` | The app has its own S3 storage: keep using it |
| `--allow-local-files` | Go live even though the app saves files next to its code (they'll be lost) |
| `--no-browser` | Don't open the browser to sign in |

Tools that take things offline or change live data ask first: add `--yes` when you're sure. `toupas help` lists every command, and [Error codes](/docs/errors) explains every error.
