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

# Deployment

> Publish your Archie app to production with one click — Archie hosting, custom domains, environments, and rollbacks.

Deployment publishes your built app to a hostable URL. You deploy to Archie's hosting (one-click, custom domain, automatic TLS) or hand off the generated code for self-deploy through GitHub.

## Deployment options

* **Archie hosting** — one-click deploy, custom domain, automatic TLS, global CDN
* **Self-deploy** — pull the code via [GitHub integration](/features/github/connecting) and host on your own infrastructure

Most projects deploy to Archie. Self-deploy is for teams with specific compliance, region, or operational requirements.

## Deploying via Archie

1. Open **Deployment** in your project
2. Pick the target environment (development, staging, production)
3. Click **Deploy**

Archie builds the production bundle, runs migrations if needed, and publishes. The first deploy takes a few minutes; subsequent deploys are faster (incremental builds).

You can deploy to staging first, verify, then promote to production. See [Environments](/features/backend/environments/overview) for the promotion flow.

## Custom domains

Connect a custom domain in your project's network settings. Archie handles DNS verification and TLS certificate issuance via Let's Encrypt. Setup:

1. Add the domain in **Settings → Network**
2. Add the displayed CNAME or ANAME record at your DNS provider
3. Wait for verification (typically minutes, sometimes up to 48 hours for propagation)
4. Archie issues the TLS certificate automatically

Pro plan includes 1 custom domain per project. Team and Enterprise include multiple. See [plans and credits](/introduction/getting-started/plans-and-credits).

## Self-deploying

If you prefer to host the app yourself:

1. Connect a [GitHub repository](/features/github/connecting)
2. Pull the generated code
3. Deploy using your normal infrastructure (Vercel, Render, AWS, your own servers)

The code is standard for its stack — there is no Archie runtime requirement on the frontend. You will need to provision a database, file storage, and environment variables yourself, or point your self-hosted frontend at your Archie Core backend (which can run anywhere AWS, GCP, or Azure runs).

## Rollbacks

Every deployment is preserved. Roll back to any previous deployment in seconds:

1. Open **Deployment → History**
2. Find the version you want
3. Click **Roll back**

Rollback is instant on Archie hosting — traffic switches immediately, no rebuild. For database migrations that ran with the rolled-back deploy, see the [Environments](/features/backend/environments/overview) docs for the rollback semantics.

## Preview deployments

Pro and higher plans get a preview URL per branch. Push to a branch on GitHub, Archie builds and deploys automatically to a unique URL. Useful for sharing in-progress work with reviewers.

Preview URLs are public by default. Add password protection from project settings if needed.

## Build minutes and bandwidth

Each plan includes a monthly allotment:

* **Starter** — 100 build minutes, 100 GB CDN bandwidth
* **Professional** — 500 build minutes, 1 TB CDN bandwidth
* **Enterprise** — custom

Overages are billed at \$0.03/minute and \$0.03/GB. See the pricing page for full numbers.

## FAQ

<AccordionGroup>
  <Accordion title="Does deployment cost AI credits?">
    No. Deployments do not consume AI credits. Build minutes and bandwidth are tracked separately and counted against your plan allotment.
  </Accordion>

  <Accordion title="What happens to data during a deployment?">
    Data is preserved. Schema migrations apply automatically; destructive changes require explicit confirmation.
  </Accordion>

  <Accordion title="Can I have multiple production environments?">
    Yes via [environments](/features/backend/environments/overview). Configure each with its own variables, domain, and database.
  </Accordion>
</AccordionGroup>
